summaryrefslogtreecommitdiff
path: root/storage/connect/libdoc.cpp
diff options
context:
space:
mode:
authorOlivier Bertrand <bertrandop@gmail.com>2015-05-26 01:02:33 +0200
committerOlivier Bertrand <bertrandop@gmail.com>2015-05-26 01:02:33 +0200
commitfb98632930cd320c55a8664f601c4082b3e14628 (patch)
treed422f3620569fd80957309359f2b026503900eb7 /storage/connect/libdoc.cpp
parent37840d5313213a6c704386c09090569935e97ecb (diff)
downloadmariadb-git-fb98632930cd320c55a8664f601c4082b3e14628.tar.gz
JSONColumns and XMLColumns revisited. They can retrieve their parameters directly
from the PTOS argument. For this to work, finding the table options is now split in HA_CONNECT functions and exported functions available from out of ha_connect. modified: storage/connect/ha_connect.cc modified: storage/connect/libdoc.cpp modified: storage/connect/mycat.h modified: storage/connect/plgdbsem.h modified: storage/connect/tabjson.cpp modified: storage/connect/tabjson.h modified: storage/connect/tabxml.cpp modified: storage/connect/tabxml.h The BIN table formats have been changed to handle the case of floating point values when used with Big Endian or Little Endian machines. modified: storage/connect/ha_connect.cc modified: storage/connect/mysql-test/connect/r/bin.result modified: storage/connect/mysql-test/connect/t/bin.test modified: storage/connect/reldef.cpp modified: storage/connect/tabdos.cpp modified: storage/connect/tabdos.h modified: storage/connect/tabfix.cpp modified: storage/connect/tabfix. h
Diffstat (limited to 'storage/connect/libdoc.cpp')
-rw-r--r--storage/connect/libdoc.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/storage/connect/libdoc.cpp b/storage/connect/libdoc.cpp
index 7d1d014c48b..c2882fc0d7c 100644
--- a/storage/connect/libdoc.cpp
+++ b/storage/connect/libdoc.cpp
@@ -533,8 +533,8 @@ int LIBXMLDOC::DumpDoc(PGLOBAL g, char *ofn)
// This function does not crash (
if (xmlSaveFormatFileEnc((const char *)ofn, Docp, Encoding, 0) < 0) {
xmlErrorPtr err = xmlGetLastError();
-
strcpy(g->Message, (err) ? err->message : "Error saving XML doc");
+ xmlResetError(Xerr);
rc = -1;
} // endif Save
// rc = xmlDocDump(of, Docp);
@@ -569,6 +569,7 @@ void LIBXMLDOC::CloseDoc(PGLOBAL g, PFBLOCK xp)
htrc("CloseDoc: xp=%p count=%d\n", xp, (xp) ? xp->Count : 0);
//if (xp && xp->Count == 1) {
+ if (xp) {
if (Nlist) {
xmlXPathFreeNodeSet(Nlist);
@@ -605,7 +606,7 @@ void LIBXMLDOC::CloseDoc(PGLOBAL g, PFBLOCK xp)
Ctxp = NULL;
} // endif Ctxp
-// } // endif Count
+ } // endif xp
CloseXML2File(g, xp, false);
} // end of Close