summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2018-05-10 13:02:19 +0200
committerSergei Golubchik <serg@mariadb.org>2018-05-10 13:02:19 +0200
commit1d411a8a440922f0538c1be254d6f4396af453a1 (patch)
tree08b06fb4a74906d49d9843ad0c467c0ade047dfa
parent9b1824dcd2564c803e58d02ac63b49ec68bd60d2 (diff)
parent0138220ff64be8ec7a530e420ad111d7cc1632e1 (diff)
downloadmariadb-git-1d411a8a440922f0538c1be254d6f4396af453a1.tar.gz
Merge branch 'connect/10.2' into 10.2
-rw-r--r--storage/connect/domdoc.cpp4
-rw-r--r--storage/connect/filamtxt.cpp2
-rw-r--r--storage/connect/ha_connect.cc12
-rw-r--r--storage/connect/jsonudf.cpp2
-rw-r--r--storage/connect/mycat.cc15
-rw-r--r--storage/connect/tabext.cpp2
-rw-r--r--storage/connect/tabjson.h1
-rw-r--r--storage/connect/user_connect.cc1
8 files changed, 15 insertions, 24 deletions
diff --git a/storage/connect/domdoc.cpp b/storage/connect/domdoc.cpp
index ba8eb829abd..9ae34a3b9ef 100644
--- a/storage/connect/domdoc.cpp
+++ b/storage/connect/domdoc.cpp
@@ -84,8 +84,8 @@ DOMDOC::DOMDOC(char *nsl, char *nsdf, char *enc, PFBLOCK fp)
: XMLDOCUMENT(nsl, nsdf, enc)
{
assert (!fp || fp->Type == TYPE_FB_XML);
- Docp = (fp) ? ((PXBLOCK)fp)->Docp : NULL;
- Nlist = NULL;
+ Docp = (fp) ? ((PXBLOCK)fp)->Docp : (MSXML2::IXMLDOMDocumentPtr)NULL;
+ Nlist = NULL;
Hr = 0;
} // end of DOMDOC constructor
diff --git a/storage/connect/filamtxt.cpp b/storage/connect/filamtxt.cpp
index 7c222eb3c80..490ca3a5fba 100644
--- a/storage/connect/filamtxt.cpp
+++ b/storage/connect/filamtxt.cpp
@@ -427,7 +427,7 @@ int TXTFAM::DeleteSortedRows(PGLOBAL g)
for (i = 0; i < Posar->GetNval(); i++) {
if ((irc = InitDelete(g, Posar->GetIntValue(ix[i]),
- Sosar->GetIntValue(ix[i])) == RC_FX))
+ Sosar->GetIntValue(ix[i]))) == RC_FX)
goto err;
// Now delete the sorted rows
diff --git a/storage/connect/ha_connect.cc b/storage/connect/ha_connect.cc
index b6f0490e6dd..6866a42dd14 100644
--- a/storage/connect/ha_connect.cc
+++ b/storage/connect/ha_connect.cc
@@ -107,13 +107,9 @@
#define MYSQL_SERVER 1
#define DONT_DEFINE_VOID
-#include "sql_class.h"
-#include "create_options.h"
-#include "mysql_com.h"
-#include "field.h"
+#include <my_global.h>
#include "sql_parse.h"
#include "sql_base.h"
-#include <sys/stat.h>
#include "sql_partition.h"
#undef OFFSET
@@ -432,7 +428,7 @@ handlerton *connect_hton= NULL;
uint GetTraceValue(void)
{return (uint)(connect_hton ? THDVAR(current_thd, xtrace) : 0);}
bool ExactInfo(void) {return THDVAR(current_thd, exact_info);}
-bool CondPushEnabled(void) {return THDVAR(current_thd, cond_push);}
+static bool CondPushEnabled(void) {return THDVAR(current_thd, cond_push);}
USETEMP UseTemp(void) {return (USETEMP)THDVAR(current_thd, use_tempfile);}
int GetConvSize(void) {return THDVAR(current_thd, conv_size);}
TYPCONV GetTypeConv(void) {return (TYPCONV)THDVAR(current_thd, type_conv);}
@@ -2813,7 +2809,7 @@ PCFIL ha_connect::CheckCond(PGLOBAL g, PCFIL filp, const Item *cond)
htrc("Cond type=%d\n", cond->type());
if (cond->type() == COND::COND_ITEM) {
- char *pb0, *pb1, *pb2, *ph0, *ph1, *ph2;
+ char *pb0, *pb1, *pb2, *ph0= 0, *ph1= 0, *ph2= 0;
bool bb = false, bh = false;
Item_cond *cond_item= (Item_cond *)cond;
@@ -5570,7 +5566,7 @@ static int connect_assisted_discovery(handlerton *, THD* thd,
} // endif p
} else if (ttp != TAB_ODBC || !(fnc & (FNC_TABLE | FNC_COL)))
- tab = table_s->table_name.str; // Default value
+ tab = (char*)table_s->table_name.str; // Default value
} // endif tab
diff --git a/storage/connect/jsonudf.cpp b/storage/connect/jsonudf.cpp
index f9276783365..39110f3ef59 100644
--- a/storage/connect/jsonudf.cpp
+++ b/storage/connect/jsonudf.cpp
@@ -1620,7 +1620,7 @@ static my_bool CheckMemory(PGLOBAL g, UDF_INIT *initid, UDF_ARGS *args, uint n,
if (AllocSarea(g, ml)) {
char errmsg[MAX_STR];
- snprintf(errmsg, sizeof(errmsg)-1, MSG(WORK_AREA), g->Message);
+ snprintf(errmsg, sizeof(errmsg) - 1, MSG(WORK_AREA), g->Message);
strcpy(g->Message, errmsg);
return true;
} // endif SareaAlloc
diff --git a/storage/connect/mycat.cc b/storage/connect/mycat.cc
index 230c0a4aa6f..5aef6d9c660 100644
--- a/storage/connect/mycat.cc
+++ b/storage/connect/mycat.cc
@@ -18,7 +18,7 @@
/* ------------- */
/* Version 1.6 */
/* */
-/* Author: Olivier Bertrand 2012 - 2017 */
+/* Author: Olivier Bertrand 2012 - 2018 */
/* */
/* WHAT THIS PROGRAM DOES: */
/* ----------------------- */
@@ -28,20 +28,13 @@
/***********************************************************************/
/* Include relevant MariaDB header file. */
/***********************************************************************/
-#include <my_config.h>
+#define DONT_DEFINE_VOID
+#include <my_global.h>
-#if defined(__WIN__)
-//#include <windows.h>
-//#include <sqlext.h>
-#elif defined(UNIX)
-#include <sys/types.h>
+#if defined(UNIX)
#include <unistd.h>
-#include <stdlib.h>
-#include <stdio.h>
#include <string.h>
#endif
-#define DONT_DEFINE_VOID
-//#include <mysql/plugin.h>
#include "handler.h"
#undef OFFSET
diff --git a/storage/connect/tabext.cpp b/storage/connect/tabext.cpp
index 64d401bef15..139e4199ed9 100644
--- a/storage/connect/tabext.cpp
+++ b/storage/connect/tabext.cpp
@@ -286,7 +286,7 @@ bool TDBEXT::MakeSrcdef(PGLOBAL g)
char *catp = strstr(Srcdef, "%s");
if (catp) {
- char *fil1, *fil2;
+ char *fil1 = 0, *fil2;
PCSZ ph = ((EXTDEF*)To_Def)->Phpos;
if (!ph)
diff --git a/storage/connect/tabjson.h b/storage/connect/tabjson.h
index 0341c0f8aa0..2ff72905e86 100644
--- a/storage/connect/tabjson.h
+++ b/storage/connect/tabjson.h
@@ -16,6 +16,7 @@ typedef class JSONDEF *PJDEF;
typedef class TDBJSON *PJTDB;
typedef class JSONCOL *PJCOL;
class TDBJSN;
+PQRYRES JSONColumns(PGLOBAL g, PCSZ db, PCSZ dsn, PTOS topt, bool info);
/***********************************************************************/
/* The JSON tree node. Can be an Object or an Array. */
diff --git a/storage/connect/user_connect.cc b/storage/connect/user_connect.cc
index 9532d7c2a8d..e2d3b664aeb 100644
--- a/storage/connect/user_connect.cc
+++ b/storage/connect/user_connect.cc
@@ -36,6 +36,7 @@
#define DONT_DEFINE_VOID
#define MYSQL_SERVER
+#include <my_global.h>
#include "sql_class.h"
#undef OFFSET