diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2016-05-10 05:15:59 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2016-05-10 05:15:59 +0200 |
commit | e706cbe5496e1829d1ddbe4d5bb0a6728204e510 (patch) | |
tree | c72d1848ac6aef07703848d0ffbe80f1336a81cd /sample/posix.c | |
parent | 69ab3addbc2dbbc90c311b2845cd25a2159435cd (diff) | |
parent | 5e01a4852b31d537307994248869caf38b4023cc (diff) |
new upstream release
Diffstat (limited to 'sample/posix.c')
-rw-r--r-- | sample/posix.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sample/posix.c b/sample/posix.c index d24ee35..f4cbe37 100644 --- a/sample/posix.c +++ b/sample/posix.c @@ -38,6 +38,8 @@ extern int main(int argc, char* argv[]) regex_t reg; UChar* pattern; + reg_set_encoding(REG_POSIX_ENCODING_ASCII); + /* default syntax (ONIG_SYNTAX_RUBY) */ pattern = (UChar* )"^a+b{2,7}[c-f]?$|uuu"; r = regcomp(®, (char* )pattern, REG_EXTENDED); @@ -89,5 +91,6 @@ extern int main(int argc, char* argv[]) x(®, pattern, (UChar* )"a\nb\n"); regfree(®); + onig_end(); return 0; } |