]> granicus.if.org Git - onig/commitdiff
remove tabs
authorK.Kosako <kkosako0@gmail.com>
Fri, 29 Mar 2019 13:39:08 +0000 (22:39 +0900)
committerK.Kosako <kkosako0@gmail.com>
Fri, 29 Mar 2019 13:39:08 +0000 (22:39 +0900)
contributed/libfuzzer-onig.cpp
doc/API.ja
windows/testc.c

index dcd7c63d937c069e7150524414dde12b865a2561..e137b73064a37ba92e9df972d0e4df552f43ab26 100644 (file)
@@ -3,14 +3,14 @@
 
 Usage:
 * compile oniguruma with something like
-       ./configure CC=clang LD=clang CFLAGS="-fsanitize-coverage=edge -fsanitize=address" \
-               LDFLAGS="-fsanitize-coverage=edge -fsanitize=address"
+    ./configure CC=clang LD=clang CFLAGS="-fsanitize-coverage=edge -fsanitize=address" \
+    LDFLAGS="-fsanitize-coverage=edge -fsanitize=address"
 * Compile libfuzzer stub and link against static libonig.a and libFuzzer.a:
-       clang++ libfuzzer-onig.cpp src/.libs/libonig.a libFuzzer.a -o libfuzzer-onig \
-               -fsanitize-coverage=edge -fsanitize=address
+    clang++ libfuzzer-onig.cpp src/.libs/libonig.a libFuzzer.a -o libfuzzer-onig \
+    -fsanitize-coverage=edge -fsanitize=address
 * Put sample patterns in directory "in/"
 * Run
-       ./libfuzzer-onig in
+    ./libfuzzer-onig in
 
 Consult libfuzzer docs for further details and how to create libFuzzer.a:
 http://llvm.org/docs/LibFuzzer.html
@@ -22,7 +22,7 @@ http://llvm.org/docs/LibFuzzer.html
 
 extern "C" int LLVMFuzzerTestOneInput(const uint8_t * Data, size_t Size)
 {
-       regex_t *reg;
+  regex_t *reg;
   OnigEncoding enc;
 
   enc = ONIG_ENCODING_UTF8;
@@ -31,13 +31,13 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t * Data, size_t Size)
   onig_initialize(&enc, 1);
 #endif
 
-       if (onig_new(&reg, Data, Data + Size, ONIG_OPTION_DEFAULT, enc,
+  if (onig_new(&reg, Data, Data + Size, ONIG_OPTION_DEFAULT, enc,
                ONIG_SYNTAX_DEFAULT, 0) == 0)
-               onig_free(reg);
+    onig_free(reg);
 
 #ifdef FULL_TEST
   onig_end();
 #endif
 
-       return 0;
+  return 0;
 }
index f160c9708102251b3071264353e846d407d8b20b..164d0b86f575ee38bdc82c0f7c1b78f79b6c3540 100644 (file)
@@ -1,4 +1,4 @@
-鬼車インターフェース Version 6.9.2   2019/03/25
+鬼車インターフェース Version 6.9.2   2019/03/29
 
 #include <oniguruma.h>
 
   8 mp: マッチパラメタ値 (match_stack_limit, retry_limit_in_match)
 
 
-# int onig_match(regex_t* reg, const UChar* str, const UChar* end, const UChar* at,
-                OnigRegion* region, OnigOptionType option)
+# int onig_match(regex_t* reg, const UChar* str, const UChar* end,
+                 const UChar* at, OnigRegion* region, OnigOptionType option)
 
   文字列の指定位置でマッチングを行い、結果とマッチ領域を返す。
 
index 2e13350caf4800a47f56bcee5754320c176f0e4a..b657682a662089f4bad2428a21c9cd813e5327cf 100644 (file)
@@ -73,7 +73,7 @@ static void xx(char* pattern, char* str, int from, int to, int mem, int not)
       }
       else {
         fprintf(stdout, "FAIL: /%s/ '%s' %d-%d : %d-%d\n", pattern, str,
-               from, to, pmatch[mem].rm_so, pmatch[mem].rm_eo);
+                from, to, pmatch[mem].rm_so, pmatch[mem].rm_eo);
         nfail++;
       }
     }
@@ -85,7 +85,7 @@ static void xx(char* pattern, char* str, int from, int to, int mem, int not)
   OnigErrorInfo einfo;
 
   r = onig_new(&reg, (UChar* )pattern, (UChar* )(pattern + SLEN(pattern)),
-              ONIG_OPTION_DEFAULT, ONIG_ENCODING_SJIS, ONIG_SYNTAX_DEFAULT, &einfo);
+         ONIG_OPTION_DEFAULT, ONIG_ENCODING_SJIS, ONIG_SYNTAX_DEFAULT, &einfo);
   if (r) {
     char s[ONIG_MAX_ERROR_MESSAGE_LEN];
     onig_error_code_to_str((UChar* )s, r, &einfo);
@@ -95,8 +95,8 @@ static void xx(char* pattern, char* str, int from, int to, int mem, int not)
   }
 
   r = onig_search(reg, (UChar* )str, (UChar* )(str + SLEN(str)),
-                 (UChar* )str, (UChar* )(str + SLEN(str)),
-                 region, ONIG_OPTION_NONE);
+                  (UChar* )str, (UChar* )(str + SLEN(str)),
+                  region, ONIG_OPTION_NONE);
   if (r < ONIG_MISMATCH) {
     char s[ONIG_MAX_ERROR_MESSAGE_LEN];
     onig_error_code_to_str((UChar* )s, r);
@@ -127,7 +127,7 @@ static void xx(char* pattern, char* str, int from, int to, int mem, int not)
       }
       else {
         fprintf(stdout, "FAIL: /%s/ '%s' %d-%d : %d-%d\n", pattern, str,
-               from, to, region->beg[mem], region->end[mem]);
+                from, to, region->beg[mem], region->end[mem]);
         nfail++;
       }
     }