[Groonga-commit] groonga/groonga at a384ed2 [master] Ensure clearing output buffer for each grn_ctx_send

Back to archive index

Kouhei Sutou null+****@clear*****
Fri Aug 26 17:44:11 JST 2016


Kouhei Sutou	2016-08-03 14:19:01 +0900 (Wed, 03 Aug 2016)

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

  Message:
    Ensure clearing output buffer for each grn_ctx_send
    
    groonga/groonga#330 and mroonga/mroonga#111 may also be fixed.

  Modified files:
    lib/ctx.c

  Modified: lib/ctx.c (+1 -0)
===================================================================
--- lib/ctx.c    2016-08-03 14:02:47 +0900 (fca882e)
+++ lib/ctx.c    2016-08-03 14:19:01 +0900 (27a5ba4)
@@ -1307,6 +1307,7 @@ grn_ctx_send(grn_ctx *ctx, const char *str, unsigned int str_len, int flags)
         grn_expr_exec(ctx, expr, 0);
       } else {
         if (comment_command_p(str, str_len)) { goto output; };
+        GRN_BULK_REWIND(ctx->impl->output.buf);
         ctx->impl->output.type = GRN_CONTENT_JSON;
         ctx->impl->output.mime_type = "application/json";
         ctx->impl->output.is_pretty = GRN_FALSE;
-------------- next part --------------
HTML����������������������������...
Download 



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