mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
Merge branch '10.5' into 10.6
This commit is contained in:
@@ -14,12 +14,12 @@
|
||||
#include "my_global.h"
|
||||
#include <m_string.h>
|
||||
#include <fcntl.h>
|
||||
#if defined(__WIN__)
|
||||
#if defined(_WIN32)
|
||||
#include <io.h>
|
||||
#include <winsock2.h>
|
||||
//#include <windows.h>
|
||||
#include <comdef.h>
|
||||
#else // !__WIN__
|
||||
#else // !_WIN32
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
#include <netinet/in.h>
|
||||
@@ -27,7 +27,7 @@
|
||||
//#include <ctype.h>
|
||||
#include "osutil.h"
|
||||
#define _O_RDONLY O_RDONLY
|
||||
#endif // !__WIN__
|
||||
#endif // !_WIN32
|
||||
#include "resource.h" // for IDS_COLUMNS
|
||||
|
||||
#define INCLUDE_TDBXML
|
||||
@@ -52,11 +52,11 @@
|
||||
|
||||
extern "C" char version[];
|
||||
|
||||
#if defined(__WIN__) && defined(DOMDOC_SUPPORT)
|
||||
#if defined(_WIN32) && defined(DOMDOC_SUPPORT)
|
||||
#define XMLSUP "MS-DOM"
|
||||
#else // !__WIN__
|
||||
#else // !_WIN32
|
||||
#define XMLSUP "libxml2"
|
||||
#endif // !__WIN__
|
||||
#endif // !_WIN32
|
||||
|
||||
#define TYPE_UNKNOWN 12 /* Must be greater than other types */
|
||||
#define XLEN(M) sizeof(M) - strlen(M) - 1 /* To avoid overflow*/
|
||||
@@ -179,11 +179,11 @@ PQRYRES XMLColumns(PGLOBAL g, char *db, char *tab, PTOS topt, bool info)
|
||||
tdp->Skip = GetBooleanTableOption(g, topt, "Skipnull", false);
|
||||
|
||||
if (!(op = GetStringTableOption(g, topt, "Xmlsup", NULL)))
|
||||
#if defined(__WIN__)
|
||||
#if defined(_WIN32)
|
||||
tdp->Usedom = true;
|
||||
#else // !__WIN__
|
||||
#else // !_WIN32
|
||||
tdp->Usedom = false;
|
||||
#endif // !__WIN__
|
||||
#endif // !_WIN32
|
||||
else
|
||||
tdp->Usedom = (toupper(*op) == 'M' || toupper(*op) == 'D');
|
||||
|
||||
@@ -531,7 +531,7 @@ bool XMLDEF::DefineAM(PGLOBAL g, LPCSTR am, int poff)
|
||||
XmlDB = GetStringCatInfo(g, "XmlDB", NULL);
|
||||
Nslist = GetStringCatInfo(g, "Nslist", NULL);
|
||||
DefNs = GetStringCatInfo(g, "DefNs", NULL);
|
||||
Limit = GetIntCatInfo("Limit", 10);
|
||||
Limit = GetIntCatInfo("Limit", 50);
|
||||
Xpand = GetBoolCatInfo("Expand", false);
|
||||
Header = GetIntCatInfo("Header", 0);
|
||||
GetCharCatInfo("Xmlsup", "*", buf, sizeof(buf));
|
||||
@@ -539,11 +539,11 @@ bool XMLDEF::DefineAM(PGLOBAL g, LPCSTR am, int poff)
|
||||
// Note that if no support is specified, the default is MS-DOM
|
||||
// on Windows and libxml2 otherwise
|
||||
if (*buf == '*')
|
||||
#if defined(__WIN__)
|
||||
#if defined(_WIN32)
|
||||
Usedom = true;
|
||||
#else // !__WIN__
|
||||
#else // !_WIN32
|
||||
Usedom = false;
|
||||
#endif // !__WIN__
|
||||
#endif // !_WIN32
|
||||
else
|
||||
Usedom = (toupper(*buf) == 'M' || toupper(*buf) == 'D');
|
||||
|
||||
@@ -976,7 +976,7 @@ bool TDBXML::Initialize(PGLOBAL g)
|
||||
|
||||
|
||||
Docp->SetNofree(true); // For libxml2
|
||||
#if defined(__WIN__)
|
||||
#if defined(_WIN32)
|
||||
} catch (_com_error e) {
|
||||
// We come here if a DOM command threw an error
|
||||
char buf[128];
|
||||
@@ -990,7 +990,7 @@ bool TDBXML::Initialize(PGLOBAL g)
|
||||
sprintf(g->Message, "%s hr=%x", MSG(COM_ERROR), e.Error());
|
||||
|
||||
goto error;
|
||||
#endif // __WIN__
|
||||
#endif // _WIN32
|
||||
#if !defined(UNIX)
|
||||
} catch(...) {
|
||||
// Other errors
|
||||
|
Reference in New Issue
Block a user