From e0fa2ce40f03add01bb3d934480e74e3ee64dd6c Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Tue, 14 Feb 2017 18:04:35 +0100 Subject: [PATCH] bugfix: uninitialized variable fixes crashes on win32-debug --- sql/item_jsonfunc.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sql/item_jsonfunc.cc b/sql/item_jsonfunc.cc index d955ddb53df..59d49b81d4a 100644 --- a/sql/item_jsonfunc.cc +++ b/sql/item_jsonfunc.cc @@ -2978,14 +2978,13 @@ String *Item_func_json_format::val_str(String *str) { String *js= args[0]->val_str(&tmp_js); json_engine_t je; - int tab_size; + int tab_size= 4; if ((null_value= args[0]->null_value)) return 0; if (fmt == DETAILED) { - tab_size= 4; if (arg_count > 1) { tab_size= args[1]->val_int();