[Groonga-commit] groonga/groonga at 79dd236 [master] Delay initialize position until it is needed

Back to archive index

Kouhei Sutou null+****@clear*****
Thu Apr 30 19:19:57 JST 2015


Kouhei Sutou	2015-04-30 19:19:57 +0900 (Thu, 30 Apr 2015)

  New Revision: 79dd236d49c0e880da1724064887ee6a2d10d026
  https://github.com/groonga/groonga/commit/79dd236d49c0e880da1724064887ee6a2d10d026

  Message:
    Delay initialize position until it is needed

  Modified files:
    lib/proc.c

  Modified: lib/proc.c (+1 -1)
===================================================================
--- lib/proc.c    2015-04-30 19:18:48 +0900 (e207d3f)
+++ lib/proc.c    2015-04-30 19:19:57 +0900 (9136bee)
@@ -980,7 +980,6 @@ grn_select(grn_ctx *ctx, const char *table, unsigned int table_len,
         if (query_len) {
           grn_expr_flags flags;
           grn_obj query_expander_buf;
-          GRN_TEXT_INIT(&query_expander_buf, 0);
           flags = GRN_EXPR_SYNTAX_QUERY;
           if (query_flags_len) {
             flags |= grn_parse_query_flags(ctx, query_flags, query_flags_len);
@@ -990,6 +989,7 @@ grn_select(grn_ctx *ctx, const char *table, unsigned int table_len,
           } else {
             flags |= GRN_EXPR_ALLOW_PRAGMA|GRN_EXPR_ALLOW_COLUMN;
           }
+          GRN_TEXT_INIT(&query_expander_buf, 0);
           if (query_expander_len) {
             if (expand_query(ctx, query, query_len, flags,
                              query_expander, query_expander_len,
-------------- next part --------------
HTML����������������������������...
Descargar 



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