]> granicus.if.org Git - onig/commitdiff
output warning if onig_initialize() is not called explicitly
authorK.Kosako <kkosako0@gmail.com>
Sat, 13 Aug 2016 14:28:01 +0000 (23:28 +0900)
committerK.Kosako <kkosako0@gmail.com>
Sat, 13 Aug 2016 14:28:01 +0000 (23:28 +0900)
src/regcomp.c

index 2fac4126f076babbe7490afe92a5d48bb9115ceb..3cc7a91fe4737b6a1275237d57daffb29ff26e3e 100644 (file)
@@ -5435,6 +5435,8 @@ onig_reg_init(regex_t* reg, OnigOptionType option,
     r = onig_initialize_encoding(enc);
     if (r != 0)
       return ONIGERR_FAIL_TO_INITIALIZE;
+
+    onig_warning("You didn't call onig_initialize() explicitly");
 #endif
   }