Commit 54f32928 authored by Alexander Barkov's avatar Alexander Barkov

Fixing warnings (mostly "no previous declaration")

modified:
  storage/connect/ha_connect.cc
  storage/connect/maputil.h
  storage/connect/odbconn.cpp
  storage/connect/osutil.c
  storage/connect/osutil.h
  storage/connect/tabmysql.cpp
  storage/connect/tabutil.cpp
  storage/connect/tabutil.h
parent 33d1689f
...@@ -3311,7 +3311,6 @@ static int connect_assisted_discovery(handlerton *hton, THD* thd, ...@@ -3311,7 +3311,6 @@ static int connect_assisted_discovery(handlerton *hton, THD* thd,
bool ok= false, dbf= false; bool ok= false, dbf= false;
TABTYPE ttp= TAB_UNDEF; TABTYPE ttp= TAB_UNDEF;
MEM_ROOT *mem= thd->mem_root; MEM_ROOT *mem= thd->mem_root;
CHARSET_INFO *cs;
PQRYRES qrp; PQRYRES qrp;
PCOLRES crp; PCOLRES crp;
PGLOBAL g= GetPlug(thd, NULL); PGLOBAL g= GetPlug(thd, NULL);
...@@ -3567,7 +3566,6 @@ static int connect_assisted_discovery(handlerton *hton, THD* thd, ...@@ -3567,7 +3566,6 @@ static int connect_assisted_discovery(handlerton *hton, THD* thd,
rem= NULL; rem= NULL;
typ= len= dec= 0; typ= len= dec= 0;
tm= NOT_NULL_FLAG; tm= NOT_NULL_FLAG;
cs= NULL;
for (crp= qrp->Colresp; crp; crp= crp->Next) for (crp= qrp->Colresp; crp; crp= crp->Next)
switch (crp->Fld) { switch (crp->Fld) {
......
...@@ -13,7 +13,6 @@ typedef struct { ...@@ -13,7 +13,6 @@ typedef struct {
HANDLE CreateFileMap(PGLOBAL, LPCSTR, MEMMAP *, MODE, bool); HANDLE CreateFileMap(PGLOBAL, LPCSTR, MEMMAP *, MODE, bool);
bool CloseMemMap(void *memory, size_t dwSize); bool CloseMemMap(void *memory, size_t dwSize);
my_bool CloseFileHandle(HANDLE h);
#ifdef __cplusplus #ifdef __cplusplus
} }
......
...@@ -175,7 +175,7 @@ int TranslateSQLType(int stp, int prec, int& len) ...@@ -175,7 +175,7 @@ int TranslateSQLType(int stp, int prec, int& len)
/***********************************************************************/ /***********************************************************************/
/* Allocate the structure used to refer to the result set. */ /* Allocate the structure used to refer to the result set. */
/***********************************************************************/ /***********************************************************************/
CATPARM *AllocCatInfo(PGLOBAL g, CATINFO fid, char *tab, PQRYRES qrp) static CATPARM *AllocCatInfo(PGLOBAL g, CATINFO fid, char *tab, PQRYRES qrp)
{ {
size_t i, m, n; size_t i, m, n;
CATPARM *cap; CATPARM *cap;
......
...@@ -142,10 +142,12 @@ my_bool CloseFileHandle(HANDLE h) ...@@ -142,10 +142,12 @@ my_bool CloseFileHandle(HANDLE h)
return (close(h)) ? TRUE : FALSE; return (close(h)) ? TRUE : FALSE;
} /* end of CloseFileHandle */ } /* end of CloseFileHandle */
#if 0
void Sleep(DWORD time) void Sleep(DWORD time)
{ {
//FIXME: TODO //FIXME: TODO
} /* end of Sleep */ } /* end of Sleep */
#endif
int GetLastError() int GetLastError()
{ {
...@@ -213,6 +215,7 @@ int _isatty(int fileNo) ...@@ -213,6 +215,7 @@ int _isatty(int fileNo)
return isatty(fileNo); return isatty(fileNo);
} /* end of _isatty */ } /* end of _isatty */
#if 0
/* This function is ridiculous and should be revisited */ /* This function is ridiculous and should be revisited */
DWORD FormatMessage(DWORD dwFlags, LPCVOID lpSource, DWORD dwMessageId, DWORD FormatMessage(DWORD dwFlags, LPCVOID lpSource, DWORD dwMessageId,
DWORD dwLanguageId, LPSTR lpBuffer, DWORD nSize, ...) DWORD dwLanguageId, LPSTR lpBuffer, DWORD nSize, ...)
...@@ -227,5 +230,6 @@ DWORD FormatMessage(DWORD dwFlags, LPCVOID lpSource, DWORD dwMessageId, ...@@ -227,5 +230,6 @@ DWORD FormatMessage(DWORD dwFlags, LPCVOID lpSource, DWORD dwMessageId,
strncpy(lpBuffer, buff, nSize); strncpy(lpBuffer, buff, nSize);
return min(n, nSize); return min(n, nSize);
} /* end of FormatMessage */ } /* end of FormatMessage */
#endif
#endif // UNIX #endif // UNIX
...@@ -52,4 +52,14 @@ typedef __int64 FILEPOS; ...@@ -52,4 +52,14 @@ typedef __int64 FILEPOS;
#define XSTR(x) ((x)?(x):"<null>") #define XSTR(x) ((x)?(x):"<null>")
#ifdef __cplusplus
extern "C" {
#endif
my_bool CloseFileHandle(HANDLE h);
#ifdef __cplusplus
}
#endif
#endif /* __OSUTIL_H__ */ #endif /* __OSUTIL_H__ */
...@@ -57,6 +57,7 @@ ...@@ -57,6 +57,7 @@
#include "reldef.h" #include "reldef.h"
#include "tabmysql.h" #include "tabmysql.h"
#include "valblk.h" #include "valblk.h"
#include "tabutil.h"
#if defined(_CONSOLE) #if defined(_CONSOLE)
void PrintResult(PGLOBAL, PSEM, PQRYRES); void PrintResult(PGLOBAL, PSEM, PQRYRES);
...@@ -65,9 +66,6 @@ void PrintResult(PGLOBAL, PSEM, PQRYRES); ...@@ -65,9 +66,6 @@ void PrintResult(PGLOBAL, PSEM, PQRYRES);
extern "C" int trace; extern "C" int trace;
extern MYSQL_PLUGIN_IMPORT uint mysqld_port; extern MYSQL_PLUGIN_IMPORT uint mysqld_port;
// This function is located in tabutil.cpp
void Remove_tshp(PCATLG cat);
/* -------------- Implementation of the MYSQLDEF class --------------- */ /* -------------- Implementation of the MYSQLDEF class --------------- */
/***********************************************************************/ /***********************************************************************/
......
...@@ -396,7 +396,7 @@ int TDBPRX::GetMaxSize(PGLOBAL g) ...@@ -396,7 +396,7 @@ int TDBPRX::GetMaxSize(PGLOBAL g)
{ {
if (MaxSize < 0) { if (MaxSize < 0) {
if (InitTable(g)) if (InitTable(g))
return NULL; return 0;
MaxSize = Tdbp->GetMaxSize(g); MaxSize = Tdbp->GetMaxSize(g);
} // endif MaxSize } // endif MaxSize
......
...@@ -20,6 +20,8 @@ TABLE_SHARE *GetTableShare(PGLOBAL g, THD *thd, const char *db, ...@@ -20,6 +20,8 @@ TABLE_SHARE *GetTableShare(PGLOBAL g, THD *thd, const char *db,
PQRYRES TabColumns(PGLOBAL g, THD *thd, const char *db, PQRYRES TabColumns(PGLOBAL g, THD *thd, const char *db,
const char *name, bool info); const char *name, bool info);
void Remove_tshp(PCATLG cat);
/* -------------------------- PROXY classes -------------------------- */ /* -------------------------- PROXY classes -------------------------- */
/***********************************************************************/ /***********************************************************************/
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment