summaryrefslogtreecommitdiff
path: root/src/big5.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/big5.c')
-rw-r--r--src/big5.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/big5.c b/src/big5.c
index 3c90eaa..3d44975 100644
--- a/src/big5.c
+++ b/src/big5.c
@@ -54,6 +54,12 @@ big5_mbc_enc_len(const UChar* p)
return EncLen_BIG5[*p];
}
+static int
+is_valid_mbc_string(const UChar* s, const UChar* end)
+{
+ return onigenc_length_check_is_valid_mbc_string(ONIG_ENCODING_BIG5, s, end);
+}
+
static OnigCodePoint
big5_mbc_to_code(const UChar* p, const UChar* end)
{
@@ -160,5 +166,6 @@ OnigEncodingType OnigEncodingBIG5 = {
big5_left_adjust_char_head,
big5_is_allowed_reverse_match,
NULL, /* init */
- NULL /* is_initialized */
+ NULL, /* is_initialized */
+ is_valid_mbc_string
};