[Groonga-commit] groonga/groonga at ad11e1f [master] pat_inspect_node: output all available nodes

Back to archive index

naoa null+****@clear*****
Fri Jan 15 00:11:33 JST 2016


naoa	2016-01-15 00:11:33 +0900 (Fri, 15 Jan 2016)

  New Revision: ad11e1f03ca05a6bd726cf4b1347fb4496d6a346
  https://github.com/groonga/groonga/commit/ad11e1f03ca05a6bd726cf4b1347fb4496d6a346

  Merged cc41923: Merge pull request #452 from naoa/fix-pat-inspect-node

  Message:
    pat_inspect_node: output all available nodes

  Modified files:
    lib/pat.c

  Modified: lib/pat.c (+7 -9)
===================================================================
--- lib/pat.c    2016-01-14 23:20:52 +0900 (daa3014)
+++ lib/pat.c    2016-01-15 00:11:33 +0900 (218f50a)
@@ -2664,6 +2664,13 @@ grn_pat_inspect_node(grn_ctx *ctx, grn_pat *pat, grn_id id, int check,
   grn_text_lltoa(ctx, buf, id);
 
   if (c > check) {
+    GRN_TEXT_PUTS(ctx, buf, "\n");
+    grn_pat_inspect_node(ctx, pat, node->lr[0], c, key_buf,
+                         indent + 2, "L:", buf);
+    GRN_TEXT_PUTS(ctx, buf, "\n");
+    grn_pat_inspect_node(ctx, pat, node->lr[1], c, key_buf,
+                         indent + 2, "R:", buf);
+  } else {
     int key_size;
     uint8_t *key;
 
@@ -2691,15 +2698,6 @@ grn_pat_inspect_node(grn_ctx *ctx, grn_pat *pat, grn_id id, int check,
     }
     GRN_TEXT_PUTS(ctx, buf, "]");
   }
-
-  if (c > check) {
-    GRN_TEXT_PUTS(ctx, buf, "\n");
-    grn_pat_inspect_node(ctx, pat, node->lr[0], c, key_buf,
-                         indent + 2, "L:", buf);
-    GRN_TEXT_PUTS(ctx, buf, "\n");
-    grn_pat_inspect_node(ctx, pat, node->lr[1], c, key_buf,
-                         indent + 2, "R:", buf);
-  }
 }
 
 void
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index