From 531698e0da307943dff5ee6830a241d6829345cd Mon Sep 17 00:00:00 2001 From: Olivier Bertrand Date: Sat, 6 May 2017 00:08:20 +0200 Subject: Fix MDEV-12603 Insert replaces values in ZIP file modified: storage/connect/filamzip.cpp modified: storage/connect/filamzip.h Fix MDEV-12686 Handle null in json Fix MDEV-12688 Insert does not handle type TINYINT modified: storage/connect/json.cpp modified: storage/connect/tabjson.cpp --- storage/connect/json.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'storage/connect/json.cpp') diff --git a/storage/connect/json.cpp b/storage/connect/json.cpp index 6817439a635..2aca1377d69 100644 --- a/storage/connect/json.cpp +++ b/storage/connect/json.cpp @@ -370,16 +370,16 @@ PJVAL ParseValue(PGLOBAL g, int& i, STRG& src, bool *pty) PJVAL jvp = new(g) JVALUE; for (; i < len; i++) - switch (s[i]) { - case '\n': - pty[0] = pty[1] = false; - case '\r': - case ' ': - case '\t': - break; - default: - goto suite; - } // endswitch + switch (s[i]) { + case '\n': + pty[0] = pty[1] = false; + case '\r': + case ' ': + case '\t': + break; + default: + goto suite; + } // endswitch suite: switch (s[i]) { @@ -1432,7 +1432,7 @@ void JVALUE::SetTiny(PGLOBAL g, char n) { Value = AllocateValue(g, &n, TYPE_TINY); Jsp = NULL; -} // end of SetInteger +} // end of SetTiny /***********************************************************************/ /* Set the Value's value as the given big integer. */ @@ -1466,6 +1466,6 @@ void JVALUE::SetString(PGLOBAL g, PSZ s, short c) /***********************************************************************/ bool JVALUE::IsNull(void) { - return (Jsp) ? Jsp->IsNull() : (Value) ? Value->IsZero() : true; + return (Jsp) ? Jsp->IsNull() : (Value) ? Value->IsNull() : true; } // end of IsNull -- cgit v1.2.1