summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOlivier Bertrand <bertrandop@gmail.com>2015-01-24 11:54:12 +0100
committerOlivier Bertrand <bertrandop@gmail.com>2015-01-24 11:54:12 +0100
commit7ebd3f6fed16472b466d6788714b46eb2cd685bd (patch)
treead659de3ffb09e81a3c2b887cdfea552dd6cfcbf
parentdbf690b5d170d16c052edc621819769ec0da4373 (diff)
parenta87bb05a7e4f43299512681eef8f835939e0ca3d (diff)
downloadmariadb-git-7ebd3f6fed16472b466d6788714b46eb2cd685bd.tar.gz
- Commit merged files (just changing some ending CRLF to LF)
modified: storage/connect/json.cpp storage/connect/xobject.cpp
-rw-r--r--storage/connect/json.cpp13
-rw-r--r--storage/connect/xobject.cpp28
2 files changed, 21 insertions, 20 deletions
diff --git a/storage/connect/json.cpp b/storage/connect/json.cpp
index c924ed3d558..c49678769b7 100644
--- a/storage/connect/json.cpp
+++ b/storage/connect/json.cpp
@@ -725,12 +725,13 @@ bool JOUTFILE::Escape(const char *s)
for (unsigned int i = 0; i < strlen(s); i++)
switch (s[i]) {
- case '\t': fputs("\\t", Stream); break;
- case '\n': fputs("\\n", Stream); break;
- case '\r': fputs("\\r", Stream); break;
- case '\b': fputs("\\b", Stream); break;
- case '\f': fputs("\\f", Stream); break;
- case '"': fputs("\\\"", Stream); break;
+ case '\t': fputs("\\t", Stream); break;
+ case '\n': fputs("\\n", Stream); break;
+ case '\r': fputs("\\r", Stream); break;
+ case '\b': fputs("\\b", Stream); break;
+ case '\f': fputs("\\f", Stream); break;
+ case '\\': fputs("\\\\", Stream); break;
+ case '"': fputs("\\\"", Stream); break;
default:
fputc(s[i], Stream);
break;
diff --git a/storage/connect/xobject.cpp b/storage/connect/xobject.cpp
index b9a0236e7c8..817acb561fe 100644
--- a/storage/connect/xobject.cpp
+++ b/storage/connect/xobject.cpp
@@ -355,20 +355,20 @@ bool STRING::Append_quoted(PSZ s)
if (s) for (char *p = s; !b && *p; p++)
switch (*p) {
- case '\'':
- case '\\':
- case '\t':
- case '\n':
- case '\r':
- case '\b':
- case '\f': b |= Append('\\');
- // passthru
- default:
- b |= Append(*p);
- break;
- } // endswitch *p
-
- return (b |= Append('\''));
+ case '\'':
+ case '\\':
+ case '\t':
+ case '\n':
+ case '\r':
+ case '\b':
+ case '\f': b |= Append('\\');
+ // passthru
+ default:
+ b |= Append(*p);
+ break;
+ } // endswitch *p
+
+ return (b |= Append('\''));
} // end of Append_quoted
/***********************************************************************/