Commit ff4018aa authored by tulin@build.mysql.com's avatar tulin@build.mysql.com

merge resolve

parents 6fffe590 bb9f7a93
...@@ -163,6 +163,7 @@ tonu@hundin.mysql.fi ...@@ -163,6 +163,7 @@ tonu@hundin.mysql.fi
tonu@volk.internalnet tonu@volk.internalnet
tonu@x153.internalnet tonu@x153.internalnet
tonu@x3.internalnet tonu@x3.internalnet
tulin@build.mysql.com
ulli@morbus.(none) ulli@morbus.(none)
venu@hundin.mysql.fi venu@hundin.mysql.fi
venu@myvenu.com venu@myvenu.com
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
# along with this program; if not, write to the Free Software # along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
INCLUDES = @MT_INCLUDES@ -I$(top_srcdir)/include INCLUDES = @MT_INCLUDES@ -I$(top_srcdir)/include @ndbcluster_includes@
LDADD = @CLIENT_EXTRA_LDFLAGS@ ../mysys/libmysys.a \ LDADD = @CLIENT_EXTRA_LDFLAGS@ ../mysys/libmysys.a \
../dbug/libdbug.a ../strings/libmystrings.a ../dbug/libdbug.a ../strings/libmystrings.a
bin_PROGRAMS = replace comp_err perror resolveip my_print_defaults \ bin_PROGRAMS = replace comp_err perror resolveip my_print_defaults \
......
...@@ -23,15 +23,27 @@ ...@@ -23,15 +23,27 @@
#include <m_string.h> #include <m_string.h>
#include <errno.h> #include <errno.h>
#include <my_getopt.h> #include <my_getopt.h>
#ifdef HAVE_NDBCLUSTER_DB
#include "../ndb/src/ndbapi/ndberror.c"
#endif
static my_bool verbose, print_all_codes; static my_bool verbose, print_all_codes;
#ifdef HAVE_NDBCLUSTER_DB
static my_bool ndb_code;
static char ndb_string[1024];
#endif
static struct my_option my_long_options[] = static struct my_option my_long_options[] =
{ {
{"help", '?', "Displays this help and exits.", 0, 0, 0, GET_NO_ARG, {"help", '?', "Displays this help and exits.", 0, 0, 0, GET_NO_ARG,
NO_ARG, 0, 0, 0, 0, 0, 0}, NO_ARG, 0, 0, 0, 0, 0, 0},
{"info", 'I', "Synonym for --help.", 0, 0, 0, GET_NO_ARG, {"info", 'I', "Synonym for --help.", 0, 0, 0, GET_NO_ARG,
NO_ARG, 0, 0, 0, 0, 0, 0}, NO_ARG, 0, 0, 0, 0, 0, 0},
#ifdef HAVE_NDBCLUSTER_DB
{"ndb", 0, "Ndbcluster storage engine specific error codes.", (gptr*) &ndb_code,
(gptr*) &ndb_code, 0, GET_BOOL, NO_ARG, 1, 0, 0, 0, 0, 0},
#endif
#ifdef HAVE_SYS_ERRLIST #ifdef HAVE_SYS_ERRLIST
{"all", 'a', "Print all the error messages and the number.", {"all", 'a', "Print all the error messages and the number.",
(gptr*) &print_all_codes, (gptr*) &print_all_codes, 0, GET_BOOL, NO_ARG, (gptr*) &print_all_codes, (gptr*) &print_all_codes, 0, GET_BOOL, NO_ARG,
...@@ -199,6 +211,16 @@ int main(int argc,char *argv[]) ...@@ -199,6 +211,16 @@ int main(int argc,char *argv[])
{ {
found=0; found=0;
code=atoi(*argv); code=atoi(*argv);
#ifdef HAVE_NDBCLUSTER_DB
if (ndb_code)
{
if (ndb_error_string(code, ndb_string, 1024) < 0)
msg= 0;
else
msg= ndb_string;
}
else
#endif
msg = strerror(code); msg = strerror(code);
if (msg) if (msg)
{ {
......
...@@ -21,57 +21,34 @@ LIBPREFIX := lib ...@@ -21,57 +21,34 @@ LIBPREFIX := lib
fixpath = $1 fixpath = $1
ar_rcs = $(AR_RCS) $1 $2 ar_rcs = $(AR_RCS) $1 $2
#check-odbc = $(findstring sqlext.h, $(wildcard /usr/include/sqlext.h) $(wildcard /usr/local/include/sqlext.h)) #check-odbc = $(findstring sqlext.h, $(wildcard /usr/include/sqlext.h) $(wildcard /usr/local/include/sqlext.h))
CCFLAGS_TOP += -DHAVE_STRCASECMP
endif endif
ifeq ($(NDB_OS), WIN32) ifeq ($(NDB_OS), WIN32)
CCFLAGS_TOP += -DHAVE_STRDUP
NDB_STRLCPY := Y
NDB_STRLCAT := Y
SHLIBEXT := dll SHLIBEXT := dll
endif endif
ifeq ($(NDB_OS), LINUX) ifeq ($(NDB_OS), LINUX)
CCFLAGS_TOP += -DHAVE_STRDUP
NDB_STRLCAT := Y
NDB_STRLCPY := Y
SHLIBEXT := so SHLIBEXT := so
endif endif
ifeq ($(NDB_OS), SOLARIS) ifeq ($(NDB_OS), SOLARIS)
CCFLAGS_TOP += -DHAVE_STRDUP
NDB_STRLCAT := Y
NDB_STRLCPY := Y
SHLIBEXT := so SHLIBEXT := so
endif endif
ifeq ($(NDB_OS), HPUX) ifeq ($(NDB_OS), HPUX)
CCFLAGS_TOP += -DHAVE_STRDUP
NDB_STRLCAT := Y
NDB_STRLCPY := Y
SHLIBEXT := sl SHLIBEXT := sl
endif endif
ifeq ($(NDB_OS), MACOSX) ifeq ($(NDB_OS), MACOSX)
CCFLAGS_TOP += -DHAVE_STRLCAT
CCFLAGS_TOP += -DHAVE_STRLCAT
CCFLAGS_TOP += -DHAVE_STRLCPY
CCFLAGS_TOP += -DNDBOUT_UINTPTR CCFLAGS_TOP += -DNDBOUT_UINTPTR
SHLIBEXT := dylib SHLIBEXT := dylib
endif endif
ifeq ($(NDB_OS), OSE) ifeq ($(NDB_OS), OSE)
NDB_STRDUP := Y
NDB_STRLCAT := Y
NDB_STRLCPY := Y
SHLIBEXT := so SHLIBEXT := so
endif endif
ifeq ($(NDB_OS), SOFTOSE) ifeq ($(NDB_OS), SOFTOSE)
NDB_STRDUP := Y
NDB_STRLCAT := Y
NDB_STRLCPY := Y
SHLIBEXT := so SHLIBEXT := so
endif endif
......
...@@ -227,7 +227,7 @@ CCFLAGS_LOC += -I$(call fixpath,$(NDB_TOP)/include/util) \ ...@@ -227,7 +227,7 @@ CCFLAGS_LOC += -I$(call fixpath,$(NDB_TOP)/include/util) \
BIN_TARGET_LIBS += logger general portlib BIN_TARGET_LIBS += logger general portlib
endif endif
CCFLAGS_LOC += -I$(call fixpath,$(NDB_TOP)/include) CCFLAGS_LOC += -I$(call fixpath,$(NDB_TOP)/include) -I$(call fixpath,$(NDB_TOP)/../include)
ifeq ($(NDB_SCI), Y) ifeq ($(NDB_SCI), Y)
BIN_TARGET_LIBS += sisci BIN_TARGET_LIBS += sisci
......
...@@ -63,20 +63,12 @@ ...@@ -63,20 +63,12 @@
*/ */
#include <ndb_global.h>
#include <NdbApi.hpp> #include <NdbApi.hpp>
#include <NdbScanFilter.hpp> #include <NdbScanFilter.hpp>
#include <iostream> // Used for cout #include <iostream> // Used for cout
#ifdef SOLARIS
#include <sys/types.h>
#include <unistd.h>
#endif
#if defined LINUX || defined MACOSX
#include <time.h>
#include <unistd.h>
#endif
/** /**
* Helper sleep function * Helper sleep function
*/ */
......
...@@ -85,21 +85,13 @@ ...@@ -85,21 +85,13 @@
*/ */
#include <ndb_global.h>
#include <NdbApi.hpp> #include <NdbApi.hpp>
#include <NdbScanFilter.hpp> #include <NdbScanFilter.hpp>
// Used for cout // Used for cout
#include <iostream> #include <iostream>
#ifdef SOLARIS
#include <sys/types.h>
#include <unistd.h>
#endif
#if defined LINUX || defined MACOSX
#include <time.h>
#include <unistd.h>
#endif
/** /**
* Helper sleep function * Helper sleep function
*/ */
......
...@@ -24,7 +24,6 @@ ...@@ -24,7 +24,6 @@
#define SignalLoggerManager_H #define SignalLoggerManager_H
#include <NdbStdio.h>
#include <kernel_types.h> #include <kernel_types.h>
#include <BlockNumbers.h> #include <BlockNumbers.h>
#include <TransporterDefinitions.hpp> #include <TransporterDefinitions.hpp>
......
...@@ -17,8 +17,7 @@ ...@@ -17,8 +17,7 @@
#ifndef _LOG_LEVEL_HPP #ifndef _LOG_LEVEL_HPP
#define _LOG_LEVEL_HPP #define _LOG_LEVEL_HPP
#include <ndb_types.h> #include <ndb_global.h>
#include <assert.h>
/** /**
* *
......
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#include "SignalData.hpp" #include "SignalData.hpp"
#include <NodeBitmask.hpp> #include <NodeBitmask.hpp>
#include <NdbString.h>
#include <signaldata/DictTabInfo.hpp> #include <signaldata/DictTabInfo.hpp>
/** /**
......
...@@ -17,11 +17,9 @@ ...@@ -17,11 +17,9 @@
#ifndef SIGNAL_DATA_H #ifndef SIGNAL_DATA_H
#define SIGNAL_DATA_H #define SIGNAL_DATA_H
#include <ndb_global.h>
#include <ndb_limits.h> #include <ndb_limits.h>
#include <kernel_types.h> #include <kernel_types.h>
#include <NdbStdio.h>
#include <NdbConstant.hpp>
#include <stdlib.h>
#ifndef NDB_ASSERT #ifndef NDB_ASSERT
#ifdef VM_TRACE #ifdef VM_TRACE
......
...@@ -17,8 +17,8 @@ ...@@ -17,8 +17,8 @@
#ifndef SIGNAL_DATA_PRINT_H #ifndef SIGNAL_DATA_PRINT_H
#define SIGNAL_DATA_PRINT_H #define SIGNAL_DATA_PRINT_H
#include <ndb_global.h>
#include <kernel_types.h> #include <kernel_types.h>
#include <NdbStdio.h>
/** /**
* Typedef for a Signal Data Print Function * Typedef for a Signal Data Print Function
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
#include "LogHandler.hpp" #include "LogHandler.hpp"
class File; class File_class;
/** /**
* Logs messages to a file. The log file will be archived depending on * Logs messages to a file. The log file will be archived depending on
...@@ -104,7 +104,7 @@ private: ...@@ -104,7 +104,7 @@ private:
int m_maxNoFiles; int m_maxNoFiles;
long m_maxFileSize; long m_maxFileSize;
unsigned int m_maxLogEntries; unsigned int m_maxLogEntries;
File* m_pLogFile; File_class* m_pLogFile;
}; };
#endif #endif
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#include "Logger.hpp" #include "Logger.hpp"
#include <NdbStdio.h> // Defines NULL
/** /**
* This class is the base class for all log handlers. A log handler is * This class is the base class for all log handlers. A log handler is
......
...@@ -17,8 +17,8 @@ ...@@ -17,8 +17,8 @@
#ifndef Logger_H #ifndef Logger_H
#define Logger_H #define Logger_H
#include <ndb_global.h>
#include <BaseString.hpp> #include <BaseString.hpp>
#include <stdarg.h>
class LogHandler; class LogHandler;
class LogHandlerList; class LogHandlerList;
......
...@@ -22,8 +22,8 @@ ...@@ -22,8 +22,8 @@
//****************************************************************************** //******************************************************************************
#include <ndb_global.h> // exit
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <stdlib.h> // exit
#define REPORT_WARNING(message) \ #define REPORT_WARNING(message) \
ndbout << "WARNING: " << message << endl ndbout << "WARNING: " << message << endl
......
/* Copyright (C) 2003 MySQL AB
This program is free software; you can redistribute it and/or modify #ifndef NDBGLOBAL_H
it under the terms of the GNU General Public License as published by #define NDBGLOBAL_H
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful, #include <my_global.h>
but WITHOUT ANY WARRANTY; without even the implied warranty of #include <m_string.h>
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #include <m_ctype.h>
GNU General Public License for more details. #include <ndb_types.h>
#include <ctype.h>
#include <stdarg.h>
#include <time.h>
#include <fcntl.h>
#include <sys/param.h>
#include <sys/stat.h>
You should have received a copy of the GNU General Public License #ifndef NDB_MACOSX
along with this program; if not, write to the Free Software #include <sys/mman.h>
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #endif
#ifdef NDB_WIN32
#include <winsock2.h>
#include <ws2tcpip.h>
#include <windows.h>
#define DIR_SEPARATOR "\\"
#define PATH_MAX 256
#pragma warning(disable: 4503 4786)
#else
#define DIR_SEPARATOR "/"
#endif
#ifndef __NDBSTRING_H_INCLUDED__ #ifdef NDB_VC98
#define __NDBSTRING_H_INCLUDED__ #define STATIC_CONST(x) enum { x }
#else
#define STATIC_CONST(x) static const Uint32 x
#endif
#include <sys/types.h> #ifdef __cplusplus
#include <string.h> #include <new>
#endif
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#include <assert.h>
#ifndef HAVE_STRDUP #ifndef HAVE_STRDUP
extern char * strdup(const char *s); extern char * strdup(const char *s);
#endif #endif
...@@ -45,4 +69,4 @@ extern int strncasecmp(const char *s1, const char *s2, size_t n); ...@@ -45,4 +69,4 @@ extern int strncasecmp(const char *s1, const char *s2, size_t n);
} }
#endif #endif
#endif /* !__NDBSTRING_H_INCLUDED__ */ #endif
...@@ -21,9 +21,6 @@ ...@@ -21,9 +21,6 @@
#ifndef SYS_TYPES_H #ifndef SYS_TYPES_H
#define SYS_TYPES_H #define SYS_TYPES_H
#include <sys/types.h>
#include <stddef.h>
typedef char Int8; typedef char Int8;
typedef unsigned char Uint8; typedef unsigned char Uint8;
typedef short Int16; typedef short Int16;
......
...@@ -17,9 +17,6 @@ ...@@ -17,9 +17,6 @@
#ifndef NDB_VERSION_H #ifndef NDB_VERSION_H
#define NDB_VERSION_H #define NDB_VERSION_H
#include <stdio.h>
#include <string.h>
#include <version.h> #include <version.h>
#define MAKE_VERSION(A,B,C) (((A) << 16) | ((B) << 8) | ((C) << 0)) #define MAKE_VERSION(A,B,C) (((A) << 16) | ((B) << 8) | ((C) << 0))
......
...@@ -860,9 +860,9 @@ ...@@ -860,9 +860,9 @@
#include <ndb_types.h> #include <ndb_types.h>
#include <ndbapi_limits.h> #include <ndbapi_limits.h>
#include "AttrType.hpp" #include <AttrType.hpp>
#include <NdbError.hpp> #include <NdbError.hpp>
#include "NdbDictionary.hpp" #include <NdbDictionary.hpp>
class NdbObjectIdMap; class NdbObjectIdMap;
class NdbOperation; class NdbOperation;
...@@ -1673,7 +1673,7 @@ private: ...@@ -1673,7 +1673,7 @@ private:
*/ */
struct StartTransactionNodeSelectionData { struct StartTransactionNodeSelectionData {
StartTransactionNodeSelectionData(): StartTransactionNodeSelectionData():
fragment2PrimaryNodeMap(NULL) {}; fragment2PrimaryNodeMap(0) {};
Uint32 kValue; Uint32 kValue;
Uint32 hashValueMask; Uint32 hashValueMask;
Uint32 hashpointerValue; Uint32 hashpointerValue;
......
...@@ -18,9 +18,8 @@ ...@@ -18,9 +18,8 @@
#define NdbConnection_H #define NdbConnection_H
#include <ndb_types.h> #include <ndb_types.h>
#include "AttrType.hpp" #include <AttrType.hpp>
#include <NdbError.hpp> #include <NdbError.hpp>
#include <stdlib.h>
class NdbConnection; class NdbConnection;
class NdbOperation; class NdbOperation;
......
...@@ -17,6 +17,8 @@ ...@@ -17,6 +17,8 @@
#ifndef NDB_ERROR_HPP #ifndef NDB_ERROR_HPP
#define NDB_ERROR_HPP #define NDB_ERROR_HPP
#include <ndberror.h>
/** /**
* @struct NdbError * @struct NdbError
* @brief Contains error information * @brief Contains error information
...@@ -51,7 +53,7 @@ struct NdbError { ...@@ -51,7 +53,7 @@ struct NdbError {
* The error code indicate success<br> * The error code indicate success<br>
* (Includes classification: NdbError::NoError) * (Includes classification: NdbError::NoError)
*/ */
Success = 0, Success = ndberror_st_success,
/** /**
* The error code indicates a temporary error. * The error code indicates a temporary error.
...@@ -61,7 +63,7 @@ struct NdbError { ...@@ -61,7 +63,7 @@ struct NdbError {
* NdbError::OverloadError, NdbError::NodeShutdown * NdbError::OverloadError, NdbError::NodeShutdown
* and NdbError::TimeoutExpired.) * and NdbError::TimeoutExpired.)
*/ */
TemporaryError = 1, TemporaryError = ndberror_st_temporary,
/** /**
* The error code indicates a permanent error.<br> * The error code indicates a permanent error.<br>
...@@ -71,14 +73,14 @@ struct NdbError { ...@@ -71,14 +73,14 @@ struct NdbError {
* NdbError::UserDefinedError, NdbError::InternalError, and, * NdbError::UserDefinedError, NdbError::InternalError, and,
* NdbError::FunctionNotImplemented.) * NdbError::FunctionNotImplemented.)
*/ */
PermanentError = 2, PermanentError = ndberror_st_permanent,
/** /**
* The result/status is unknown.<br> * The result/status is unknown.<br>
* (Includes classifications: NdbError::UnknownResultError, and * (Includes classifications: NdbError::UnknownResultError, and
* NdbError::UnknownErrorCode.) * NdbError::UnknownErrorCode.)
*/ */
UnknownResult = 3 UnknownResult = ndberror_st_unknown
}; };
/** /**
...@@ -88,85 +90,85 @@ struct NdbError { ...@@ -88,85 +90,85 @@ struct NdbError {
/** /**
* Success. No error occurred. * Success. No error occurred.
*/ */
NoError = 0, NoError = ndberror_cl_none,
/** /**
* Error in application program. * Error in application program.
*/ */
ApplicationError = 1, ApplicationError = ndberror_cl_application,
/** /**
* Read operation failed due to missing record. * Read operation failed due to missing record.
*/ */
NoDataFound = 2, NoDataFound = ndberror_cl_no_data_found,
/** /**
* E.g. inserting a tuple with a primary key already existing * E.g. inserting a tuple with a primary key already existing
* in the table. * in the table.
*/ */
ConstraintViolation = 3, ConstraintViolation = ndberror_cl_constraint_violation,
/** /**
* Error in creating table or usage of table. * Error in creating table or usage of table.
*/ */
SchemaError = 4, SchemaError = ndberror_cl_schema_error,
/** /**
* Error occurred in interpreted program. * Error occurred in interpreted program.
*/ */
UserDefinedError = 5, UserDefinedError = ndberror_cl_user_defined,
/** /**
* E.g. insufficient memory for data or indexes. * E.g. insufficient memory for data or indexes.
*/ */
InsufficientSpace = 6, InsufficientSpace = ndberror_cl_insufficient_space,
/** /**
* E.g. too many active transactions. * E.g. too many active transactions.
*/ */
TemporaryResourceError = 7, TemporaryResourceError = ndberror_cl_temporary_resource,
/** /**
* Temporary failures which are probably inflicted by a node * Temporary failures which are probably inflicted by a node
* recovery in progress. Examples: information sent between * recovery in progress. Examples: information sent between
* application and NDB lost, distribution change. * application and NDB lost, distribution change.
*/ */
NodeRecoveryError = 8, NodeRecoveryError = ndberror_cl_node_recovery,
/** /**
* E.g. out of log file space. * E.g. out of log file space.
*/ */
OverloadError = 9, OverloadError = ndberror_cl_overload,
/** /**
* Timeouts, often inflicted by deadlocks in NDB. * Timeouts, often inflicted by deadlocks in NDB.
*/ */
TimeoutExpired = 10, TimeoutExpired = ndberror_cl_timeout_expired,
/** /**
* Is is unknown whether the transaction was committed or not. * Is is unknown whether the transaction was committed or not.
*/ */
UnknownResultError = 11, UnknownResultError = ndberror_cl_unknown_result,
/** /**
* A serious error in NDB has occurred. * A serious error in NDB has occurred.
*/ */
InternalError = 12, InternalError = ndberror_cl_internal_error,
/** /**
* A function used is not yet implemented. * A function used is not yet implemented.
*/ */
FunctionNotImplemented = 13, FunctionNotImplemented = ndberror_cl_function_not_implemented,
/** /**
* Error handler could not determine correct error code. * Error handler could not determine correct error code.
*/ */
UnknownErrorCode = 14, UnknownErrorCode = ndberror_cl_unknown_error_code,
/** /**
* Node shutdown * Node shutdown
*/ */
NodeShutdown = 15 NodeShutdown = ndberror_cl_node_shutdown
}; };
/** /**
...@@ -204,6 +206,22 @@ struct NdbError { ...@@ -204,6 +206,22 @@ struct NdbError {
message = 0; message = 0;
details = 0; details = 0;
} }
NdbError(const ndberror_struct & ndberror){
status = (NdbError::Status) ndberror.status;
classification = (NdbError::Classification) ndberror.classification;
code = ndberror.code;
message = ndberror.message;
details = ndberror.details;
}
operator ndberror_struct() const {
ndberror_struct ndberror;
ndberror.status = (ndberror_status_enum) status;
ndberror.classification = (ndberror_classification_enum) classification;
ndberror.code = code;
ndberror.message = message;
ndberror.details = details;
return ndberror;
}
}; };
class NdbOut& operator <<(class NdbOut&, const NdbError &); class NdbOut& operator <<(class NdbOut&, const NdbError &);
......
...@@ -157,8 +157,8 @@ public: ...@@ -157,8 +157,8 @@ public:
* the attribute, or a NULL pointer * the attribute, or a NULL pointer
* (indicating error). * (indicating error).
*/ */
NdbRecAttr *getValue(const char *anAttrName, char *aValue = NULL); NdbRecAttr *getValue(const char *anAttrName, char *aValue = 0);
NdbRecAttr *getPreValue(const char *anAttrName, char *aValue = NULL); NdbRecAttr *getPreValue(const char *anAttrName, char *aValue = 0);
/** /**
* Retrieves event resultset if available, inserted into the NdbRecAttrs * Retrieves event resultset if available, inserted into the NdbRecAttrs
...@@ -172,7 +172,7 @@ public: ...@@ -172,7 +172,7 @@ public:
* overflow and *pOverRun will indicate the number of events that have * overflow and *pOverRun will indicate the number of events that have
* overwritten. * overwritten.
*/ */
int next(int *pOverRun=NULL); int next(int *pOverRun=0);
/** /**
* In the current implementation a nodefailiure may cause loss of events, * In the current implementation a nodefailiure may cause loss of events,
......
...@@ -17,14 +17,11 @@ ...@@ -17,14 +17,11 @@
#ifndef NdbOperation_H #ifndef NdbOperation_H
#define NdbOperation_H #define NdbOperation_H
#include <stdlib.h>
#include <assert.h>
#include <ndb_types.h> #include <ndb_types.h>
#include "AttrType.hpp"
#include "NdbError.hpp" #include <AttrType.hpp>
#include "NdbReceiver.hpp" #include <NdbError.hpp>
#include <stdlib.h> #include <NdbReceiver.hpp>
class Ndb; class Ndb;
class NdbApiSignal; class NdbApiSignal;
...@@ -480,8 +477,8 @@ public: ...@@ -480,8 +477,8 @@ public:
* the attribute, or a NULL pointer * the attribute, or a NULL pointer
* (indicating error). * (indicating error).
*/ */
NdbRecAttr* getValue(const char* anAttrName, char* aValue = NULL); NdbRecAttr* getValue(const char* anAttrName, char* aValue = 0);
NdbRecAttr* getValue(Uint32 anAttrId, char* aValue = NULL); NdbRecAttr* getValue(Uint32 anAttrId, char* aValue = 0);
/** /**
* Define an attribute to set or update in query. * Define an attribute to set or update in query.
...@@ -925,7 +922,7 @@ protected: ...@@ -925,7 +922,7 @@ protected:
virtual int equal_impl(const NdbColumnImpl* anAttrObject, virtual int equal_impl(const NdbColumnImpl* anAttrObject,
const char* aValue, const char* aValue,
Uint32 len); Uint32 len);
NdbRecAttr* getValue(const NdbColumnImpl* anAttrObject, char* aValue = NULL); NdbRecAttr* getValue(const NdbColumnImpl* anAttrObject, char* aValue = 0);
int setValue(const NdbColumnImpl* anAttrObject, const char* aValue, Uint32 len); int setValue(const NdbColumnImpl* anAttrObject, const char* aValue, Uint32 len);
int incValue(const NdbColumnImpl* anAttrObject, Uint32 aValue); int incValue(const NdbColumnImpl* anAttrObject, Uint32 aValue);
int incValue(const NdbColumnImpl* anAttrObject, Uint64 aValue); int incValue(const NdbColumnImpl* anAttrObject, Uint64 aValue);
......
...@@ -17,9 +17,6 @@ ...@@ -17,9 +17,6 @@
#ifndef NdbRecAttr_H #ifndef NdbRecAttr_H
#define NdbRecAttr_H #define NdbRecAttr_H
#include <stdlib.h>
#include <ndb_types.h>
#include <NdbDictionary.hpp> #include <NdbDictionary.hpp>
#include "AttrType.hpp" #include "AttrType.hpp"
...@@ -427,9 +424,9 @@ inline ...@@ -427,9 +424,9 @@ inline
void void
NdbRecAttr::release() NdbRecAttr::release()
{ {
if (theStorageX != NULL) { if (theStorageX != 0) {
delete [] theStorageX; delete [] theStorageX;
theStorageX = NULL; theStorageX = 0;
} }
} }
...@@ -437,10 +434,10 @@ inline ...@@ -437,10 +434,10 @@ inline
void void
NdbRecAttr::init() NdbRecAttr::init()
{ {
theStorageX = NULL; theStorageX = 0;
theValue = NULL; theValue = 0;
theRef = NULL; theRef = 0;
theNext = NULL; theNext = 0;
theAttrId = 0xFFFF; theAttrId = 0xFFFF;
theNULLind = -1; theNULLind = -1;
} }
...@@ -470,7 +467,7 @@ inline ...@@ -470,7 +467,7 @@ inline
bool bool
NdbRecAttr::copyoutRequired() const NdbRecAttr::copyoutRequired() const
{ {
return theRef != theValue && theValue != NULL; return theRef != theValue && theValue != 0;
} }
inline inline
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
#define NdbReceiver_H #define NdbReceiver_H
#ifndef DOXYGEN_SHOULD_SKIP_INTERNAL // Not part of public interface #ifndef DOXYGEN_SHOULD_SKIP_INTERNAL // Not part of public interface
#include <stdlib.h> #include <ndb_types.h>
class Ndb; class Ndb;
class NdbReceiver class NdbReceiver
......
...@@ -172,25 +172,6 @@ SetValueRec::SetValueRec() : ...@@ -172,25 +172,6 @@ SetValueRec::SetValueRec() :
{ {
} }
inline
SetValueRec::~SetValueRec()
{
if ((stype == SET_STRING_ATTR1) ||
(stype == SET_INT32_ATTR1) ||
(stype == SET_UINT32_ATTR1) ||
(stype == SET_INT64_ATTR1) ||
(stype == SET_UINT64_ATTR1) ||
(stype == SET_FLOAT_ATTR1) ||
(stype == SET_DOUBLE_ATTR1))
free(anAttrName);
if ((stype == SET_STRING_ATTR1) ||
(stype == SET_STRING_ATTR2))
free(stringStruct.aStringValue);
if (next) delete next;
next = 0;
}
class SetValueRecList { class SetValueRecList {
public: public:
SetValueRecList(); SetValueRecList();
......
...@@ -18,11 +18,9 @@ ...@@ -18,11 +18,9 @@
#define NdbSchemaOp_H #define NdbSchemaOp_H
#ifndef DOXYGEN_SHOULD_SKIP_DEPRECATED #ifndef DOXYGEN_SHOULD_SKIP_DEPRECATED
#include <ndb_types.h> #include "NdbDictionary.hpp"
#include "AttrType.hpp" #include "AttrType.hpp"
#include "NdbSchemaCon.hpp" #include "NdbSchemaCon.hpp"
#include <stdlib.h>
#include "NdbDictionary.hpp"
class NdbApiSignal; class NdbApiSignal;
class Ndb; class Ndb;
......
...@@ -14,26 +14,85 @@ ...@@ -14,26 +14,85 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#ifndef NDB_UNISTD_H #ifndef NDBERROR_H
#define NDB_UNISTD_H #define NDBERROR_H
#ifdef NDB_WIN32 #ifdef __cplusplus
#include <winsock2.h> extern "C" {
#include <ws2tcpip.h> #endif
#include <windows.h>
#include <limits.h> typedef enum
{
ndberror_st_success = 0,
ndberror_st_temporary = 1,
ndberror_st_permanent = 2,
ndberror_st_unknown = 3
} ndberror_status_enum;
typedef enum
{
ndberror_cl_none = 0,
ndberror_cl_application = 1,
ndberror_cl_no_data_found = 2,
ndberror_cl_constraint_violation = 3,
ndberror_cl_schema_error = 4,
ndberror_cl_user_defined = 5,
ndberror_cl_insufficient_space = 6,
ndberror_cl_temporary_resource = 7,
ndberror_cl_node_recovery = 8,
ndberror_cl_overload = 9,
ndberror_cl_timeout_expired = 10,
ndberror_cl_unknown_result = 11,
ndberror_cl_internal_error = 12,
ndberror_cl_function_not_implemented = 13,
ndberror_cl_unknown_error_code = 14,
ndberror_cl_node_shutdown = 15
} ndberror_classification_enum;
typedef struct {
/**
* Error status.
*/
ndberror_status_enum status;
/**
* Error type
*/
ndberror_classification_enum classification;
/**
* Error code
*/
int code;
/**
* Error message
*/
const char * message;
/**
* The detailed description. This is extra information regarding the
* error which is not included in the error message.
*
* @note Is NULL when no details specified
*/
char * details;
#define DIR_SEPARATOR "\\" } ndberror_struct;
#define PATH_MAX 256
#pragma warning(disable: 4503 4786)
#else typedef ndberror_status_enum ndberror_status;
#include <unistd.h> typedef ndberror_classification_enum ndberror_classification;
#include <limits.h>
#define DIR_SEPARATOR "/" const char *ndberror_status_message(ndberror_status);
const char *ndberror_classification_message(ndberror_classification);
void ndberror_update(ndberror_struct *);
int ndb_error_string(int err_no, char *str, unsigned int size);
#ifdef __cplusplus
}
#endif #endif
#endif #endif
...@@ -102,11 +102,9 @@ ...@@ -102,11 +102,9 @@
/* --- Include files ---- */ /* --- Include files ---- */
#include <ndb_global.h>
#include <defs/pcn_types.h> #include <defs/pcn_types.h>
#include <stdio.h>
/* --- Types and definitions --- */ /* --- Types and definitions --- */
/** /**
......
...@@ -17,8 +17,7 @@ ...@@ -17,8 +17,7 @@
#ifndef PCN_TYPES_H #ifndef PCN_TYPES_H
#define PCN_TYPES_H #define PCN_TYPES_H
#include <stddef.h> #include <ndb_global.h>
#include <NdbUnistd.h>
#ifdef NDB_MACOSX #ifdef NDB_MACOSX
typedef unsigned int Size_t; typedef unsigned int Size_t;
......
/* Copyright (C) 2003 MySQL AB
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#ifndef NDB_CONSTANT_HPP
#define NDB_CONSTANT_HPP
#include <ndb_types.h>
#ifdef NDB_VC98
#define STATIC_CONST(x) enum { x }
#else
#define STATIC_CONST(x) static const Uint32 x
#endif
#endif
...@@ -17,8 +17,7 @@ ...@@ -17,8 +17,7 @@
#ifndef NDB_MEM_H #ifndef NDB_MEM_H
#define NDB_MEM_H #define NDB_MEM_H
#include <stddef.h> #include <ndb_global.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
......
...@@ -17,6 +17,8 @@ ...@@ -17,6 +17,8 @@
#ifndef NDB_TCP_H #ifndef NDB_TCP_H
#define NDB_TCP_H #define NDB_TCP_H
#include <ndb_global.h>
#if defined NDB_OSE || defined NDB_SOFTOSE #if defined NDB_OSE || defined NDB_SOFTOSE
/** /**
* Include files needed * Include files needed
...@@ -24,7 +26,6 @@ ...@@ -24,7 +26,6 @@
#include "inet.h" #include "inet.h"
#include <netdb.h> #include <netdb.h>
#include <errno.h>
#define NDB_NONBLOCK FNDELAY #define NDB_NONBLOCK FNDELAY
#define NDB_SOCKET_TYPE int #define NDB_SOCKET_TYPE int
...@@ -40,45 +41,15 @@ typedef int socklen_t; ...@@ -40,45 +41,15 @@ typedef int socklen_t;
#endif #endif
#if defined NDB_SOLARIS || defined NDB_HPUX || defined NDB_IBMAIX || defined NDB_TRU64X #if defined NDB_SOLARIS || defined NDB_HPUX || defined NDB_IBMAIX || defined NDB_TRU64X || NDB_LINUX || defined NDB_MACOSX
/**
* Include files needed
*/
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netinet/tcp.h>
#include <arpa/inet.h>
#include <unistd.h>
#include <netdb.h>
#include <errno.h>
#include <fcntl.h>
#define NDB_NONBLOCK O_NONBLOCK
#define NDB_SOCKET_TYPE int
#define NDB_INVALID_SOCKET -1
#define NDB_CLOSE_SOCKET(x) close(x)
#define InetErrno errno
#endif
#if defined NDB_LINUX || defined NDB_MACOSX
/** /**
* Include files needed * Include files needed
*/ */
#include <sys/time.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h> #include <netinet/in.h>
#include <netinet/tcp.h> #include <netinet/tcp.h>
#include <arpa/inet.h> #include <arpa/inet.h>
#include <unistd.h>
#include <netdb.h> #include <netdb.h>
#include <errno.h>
#include <fcntl.h>
#define NDB_NONBLOCK O_NONBLOCK #define NDB_NONBLOCK O_NONBLOCK
#define NDB_SOCKET_TYPE int #define NDB_SOCKET_TYPE int
...@@ -89,14 +60,12 @@ typedef int socklen_t; ...@@ -89,14 +60,12 @@ typedef int socklen_t;
#endif #endif
#ifdef NDB_WIN32 #ifdef NDB_WIN32
/** /**
* Include files needed * Include files needed
*/ */
#include <winsock2.h> #include <winsock2.h>
#include <ws2tcpip.h> #include <ws2tcpip.h>
#include <errno.h>
#define InetErrno WSAGetLastError() #define InetErrno WSAGetLastError()
#define EWOULDBLOCK WSAEWOULDBLOCK #define EWOULDBLOCK WSAEWOULDBLOCK
......
...@@ -17,8 +17,8 @@ ...@@ -17,8 +17,8 @@
#ifndef TransporterDefinitions_H #ifndef TransporterDefinitions_H
#define TransporterDefinitions_H #define TransporterDefinitions_H
#include <ndb_global.h>
#include <kernel_types.h> #include <kernel_types.h>
#include <string.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
/** /**
......
...@@ -17,9 +17,7 @@ ...@@ -17,9 +17,7 @@
#ifndef __UTIL_BASESTRING_HPP_INCLUDED__ #ifndef __UTIL_BASESTRING_HPP_INCLUDED__
#define __UTIL_BASESTRING_HPP_INCLUDED__ #define __UTIL_BASESTRING_HPP_INCLUDED__
#include <ctype.h> #include <ndb_global.h>
#include <stdlib.h>
#include <Vector.hpp> #include <Vector.hpp>
/** /**
......
...@@ -17,12 +17,9 @@ ...@@ -17,12 +17,9 @@
#ifndef NDB_BITMASK_H #ifndef NDB_BITMASK_H
#define NDB_BITMASK_H #define NDB_BITMASK_H
#include <ndb_types.h> #include <ndb_global.h>
#include <NdbConstant.hpp>
#ifndef NDB_ASSERT #ifndef NDB_ASSERT
#include <stdio.h>
#include <stdlib.h>
#define NDB_ASSERT(x, s) \ #define NDB_ASSERT(x, s) \
do { if (!(x)) { printf("%s\n", s); abort(); } } while (0) do { if (!(x)) { printf("%s\n", s); abort(); } } while (0)
#endif #endif
......
...@@ -17,8 +17,7 @@ ...@@ -17,8 +17,7 @@
#ifndef FILE_H #ifndef FILE_H
#define FILE_H #define FILE_H
#include <NdbStdio.h> #include <ndb_global.h>
#include <NdbConstant.hpp>
/** /**
* This class provides a file abstraction . It has operations * This class provides a file abstraction . It has operations
...@@ -26,7 +25,7 @@ ...@@ -26,7 +25,7 @@
* *
* @version #@ $Id: File.hpp,v 1.5 2002/04/26 13:15:38 ejonore Exp $ * @version #@ $Id: File.hpp,v 1.5 2002/04/26 13:15:38 ejonore Exp $
*/ */
class File class File_class
{ {
public: public:
/** /**
...@@ -65,7 +64,7 @@ public: ...@@ -65,7 +64,7 @@ public:
/** /**
* Default constructor. * Default constructor.
*/ */
File(); File_class();
/** /**
* Creates a new File with the specified filename and file mode. * Creates a new File with the specified filename and file mode.
...@@ -76,12 +75,12 @@ public: ...@@ -76,12 +75,12 @@ public:
* @param aFileName a filename. * @param aFileName a filename.
* @param mode the mode which the file should be opened/created with, default "r". * @param mode the mode which the file should be opened/created with, default "r".
*/ */
File(const char* aFileName, const char* mode = "r"); File_class(const char* aFileName, const char* mode = "r");
/** /**
* Destructor. * Destructor.
*/ */
~File(); ~File_class();
/** /**
* Opens/creates the file. If open() fails then 'errno' and perror() * Opens/creates the file. If open() fails then 'errno' and perror()
...@@ -198,9 +197,9 @@ private: ...@@ -198,9 +197,9 @@ private:
char m_fileName[MAX_FILE_NAME_SIZE]; char m_fileName[MAX_FILE_NAME_SIZE];
const char* m_fileMode; const char* m_fileMode;
/* Prohibit */ /* Prohibit */
File(const File& aCopy); File_class (const File_class& aCopy);
File operator = (const File&); File_class operator = (const File_class&);
bool operator == (const File&); bool operator == (const File_class&);
}; };
#endif #endif
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#ifndef INPUT_STREAM_HPP #ifndef INPUT_STREAM_HPP
#define INPUT_STREAM_HPP #define INPUT_STREAM_HPP
#include <stdio.h> #include <ndb_global.h>
#include <NdbTCP.h> #include <NdbTCP.h>
/** /**
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#ifndef __NDB_AUTO_PTR_HPP #ifndef __NDB_AUTO_PTR_HPP
#define __NDB_AUTO_PTR_HPP #define __NDB_AUTO_PTR_HPP
#include <stdlib.h> #include <ndb_global.h>
template<typename T> template<typename T>
class NdbAutoPtr { class NdbAutoPtr {
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#ifndef OUTPUT_STREAM_HPP #ifndef OUTPUT_STREAM_HPP
#define OUTPUT_STREAM_HPP #define OUTPUT_STREAM_HPP
#include <stdio.h> #include <ndb_global.h>
#include <NdbTCP.h> #include <NdbTCP.h>
/** /**
......
...@@ -17,10 +17,7 @@ ...@@ -17,10 +17,7 @@
#ifndef PROPERTIES_HPP #ifndef PROPERTIES_HPP
#define PROPERTIES_HPP #define PROPERTIES_HPP
#include <stdio.h> #include <ndb_global.h>
#include <string.h>
#include <stdlib.h>
#include <ndb_types.h>
#include <BaseString.hpp> #include <BaseString.hpp>
#include <UtilBuffer.hpp> #include <UtilBuffer.hpp>
......
...@@ -17,8 +17,7 @@ ...@@ -17,8 +17,7 @@
#ifndef SIMPLE_PROPERTIES_HPP #ifndef SIMPLE_PROPERTIES_HPP
#define SIMPLE_PROPERTIES_HPP #define SIMPLE_PROPERTIES_HPP
#include <ndb_types.h> #include <ndb_global.h>
#include <stddef.h> // offsetof
#include <NdbOut.hpp> #include <NdbOut.hpp>
/** /**
......
...@@ -17,9 +17,7 @@ ...@@ -17,9 +17,7 @@
#ifndef __BUFFER_HPP_INCLUDED__ #ifndef __BUFFER_HPP_INCLUDED__
#define __BUFFER_HPP_INCLUDED__ #define __BUFFER_HPP_INCLUDED__
#include <unistd.h> #include <ndb_global.h>
#include <errno.h>
#include <stdlib.h>
/* This class represents a buffer of binary data, where you can append /* This class represents a buffer of binary data, where you can append
* data at the end, and later read the entire bunch. * data at the end, and later read the entire bunch.
......
...@@ -17,9 +17,8 @@ ...@@ -17,9 +17,8 @@
#ifndef NDB_VECTOR_HPP #ifndef NDB_VECTOR_HPP
#define NDB_VECTOR_HPP #define NDB_VECTOR_HPP
#include <stdlib.h> #include <ndb_global.h>
#include <NdbMutex.h> #include <NdbMutex.h>
#include <string.h>
template<class T> template<class T>
struct Vector { struct Vector {
......
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
#ifndef __GETARG_H__ #ifndef __GETARG_H__
#define __GETARG_H__ #define __GETARG_H__
#include <stddef.h> #include <ndb_global.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
......
...@@ -17,8 +17,9 @@ ...@@ -17,8 +17,9 @@
#ifndef _SOCKET_IO_H #ifndef _SOCKET_IO_H
#define _SOCKET_IO_H #define _SOCKET_IO_H
#include <ndb_global.h>
#include <NdbTCP.h> #include <NdbTCP.h>
#include <stdarg.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#ifndef UUCODE_H #ifndef UUCODE_H
#define UUCODE_H #define UUCODE_H
#include <stdio.h> #include <ndb_global.h>
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
......
...@@ -14,11 +14,7 @@ ...@@ -14,11 +14,7 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <NdbUnistd.h> #include <ndb_global.h>
#include <stdlib.h>
#include <string.h>
#include <NdbStdio.h>
#include <stdarg.h>
#include <NdbApi.hpp> #include <NdbApi.hpp>
#include <common/common.hpp> #include <common/common.hpp>
#include "DiagArea.hpp" #include "DiagArea.hpp"
......
...@@ -14,14 +14,8 @@ ...@@ -14,14 +14,8 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <NdbUnistd.h> #include <ndb_global.h>
#include <NdbStdio.h>
#include <stdlib.h>
#include <errno.h>
#include <limits.h>
#include <math.h>
#include "DataField.hpp" #include "DataField.hpp"
#include <time.h>
#ifndef INT_MAX #ifndef INT_MAX
#define INT_MAX (2147483647) #define INT_MAX (2147483647)
......
...@@ -15,7 +15,6 @@ ...@@ -15,7 +15,6 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include "DataType.hpp" #include "DataType.hpp"
#include <NdbStdio.h>
// SqlType // SqlType
......
...@@ -14,9 +14,7 @@ ...@@ -14,9 +14,7 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <new> #include <ndb_global.h>
#include <string.h>
#include <NdbStdio.h>
#include "OdbcData.hpp" #include "OdbcData.hpp"
OdbcData::OdbcData() : OdbcData::OdbcData() :
......
...@@ -14,16 +14,14 @@ ...@@ -14,16 +14,14 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "DebuggerNames.hpp" #include "DebuggerNames.hpp"
#include <BlockNumbers.h> #include <BlockNumbers.h>
#include <GlobalSignalNumbers.h> #include <GlobalSignalNumbers.h>
#include <signaldata/SignalDataPrint.hpp> #include <signaldata/SignalDataPrint.hpp>
#include <NdbStdio.h>
#include <stdlib.h>
#include <string.h>
static const char * localSignalNames[MAX_GSN+1]; static const char * localSignalNames[MAX_GSN+1];
static SignalDataPrintFunction localPrintFunctions[MAX_GSN+1]; static SignalDataPrintFunction localPrintFunctions[MAX_GSN+1];
static const char * localBlockNames[NO_OF_BLOCKS]; static const char * localBlockNames[NO_OF_BLOCKS];
......
...@@ -14,6 +14,8 @@ ...@@ -14,6 +14,8 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "EventLogger.hpp" #include "EventLogger.hpp"
#include <NdbConfig.h> #include <NdbConfig.h>
...@@ -22,10 +24,6 @@ ...@@ -22,10 +24,6 @@
#include <GrepEvent.hpp> #include <GrepEvent.hpp>
#include <NodeState.hpp> #include <NodeState.hpp>
#include <version.h> #include <version.h>
#include <NdbStdio.h>
#include <string.h>
#include <ctype.h>
// //
// PUBLIC // PUBLIC
......
...@@ -14,15 +14,11 @@ ...@@ -14,15 +14,11 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "SignalLoggerManager.hpp" #include "SignalLoggerManager.hpp"
#include <LongSignal.hpp> #include <LongSignal.hpp>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include <time.h>
#include <NdbString.h>
#include <DebuggerNames.hpp> #include <DebuggerNames.hpp>
SignalLoggerManager::SignalLoggerManager() SignalLoggerManager::SignalLoggerManager()
......
...@@ -15,7 +15,6 @@ ...@@ -15,7 +15,6 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <NdbStdio.h>
#include <kernel_types.h> #include <kernel_types.h>
#include <BlockNumbers.h> #include <BlockNumbers.h>
#include <signaldata/CloseComReqConf.hpp> #include <signaldata/CloseComReqConf.hpp>
......
...@@ -15,7 +15,6 @@ ...@@ -15,7 +15,6 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <NdbStdio.h>
#include <kernel_types.h> #include <kernel_types.h>
#include <BlockNumbers.h> #include <BlockNumbers.h>
#include <signaldata/DihContinueB.hpp> #include <signaldata/DihContinueB.hpp>
......
...@@ -15,7 +15,6 @@ ...@@ -15,7 +15,6 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <NdbStdio.h>
#include <kernel_types.h> #include <kernel_types.h>
#include <BlockNumbers.h> #include <BlockNumbers.h>
#include <signaldata/PrepFailReqRef.hpp> #include <signaldata/PrepFailReqRef.hpp>
......
...@@ -15,7 +15,6 @@ ...@@ -15,7 +15,6 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <NdbStdio.h>
#include <kernel_types.h> #include <kernel_types.h>
#include <BlockNumbers.h> #include <BlockNumbers.h>
#include <signaldata/SystemError.hpp> #include <signaldata/SystemError.hpp>
......
...@@ -19,9 +19,8 @@ ...@@ -19,9 +19,8 @@
** Internal header file for editline library. ** Internal header file for editline library.
*/ */
#include <stdio.h> #include <ndb_global.h>
#include <stdlib.h>
#include <string.h>
#if defined(SYS_UNIX) #if defined(SYS_UNIX)
#include "unix.h" #include "unix.h"
#endif /* defined(SYS_UNIX) */ #endif /* defined(SYS_UNIX) */
......
...@@ -15,8 +15,7 @@ ...@@ -15,8 +15,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <stdio.h> #include <ndb_global.h>
#include <malloc.h>
char* readline(const char* prompt) char* readline(const char* prompt)
......
...@@ -20,11 +20,7 @@ ...@@ -20,11 +20,7 @@
** A "micro-shell" to test editline library. ** A "micro-shell" to test editline library.
** If given any arguments, commands aren't executed. ** If given any arguments, commands aren't executed.
*/ */
#include <stdio.h> #include <ndb_global.h>
#include <stdlib.h>
#include <unistd.h>
#include <NdbString.h>
#include <editline/editline.h> #include <editline/editline.h>
int int
......
...@@ -14,16 +14,10 @@ ...@@ -14,16 +14,10 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include "FileLogHandler.hpp" #include <FileLogHandler.hpp>
#include <File.hpp> #include <File.hpp>
#include <NdbStdio.h>
#include <sys/param.h>
#include <errno.h>
#include <string.h>
// //
// PUBLIC // PUBLIC
// //
...@@ -35,7 +29,7 @@ FileLogHandler::FileLogHandler() : ...@@ -35,7 +29,7 @@ FileLogHandler::FileLogHandler() :
m_maxLogEntries(MAX_LOG_ENTRIES) m_maxLogEntries(MAX_LOG_ENTRIES)
{ {
m_pLogFile = new File("logger.log", "a+"); m_pLogFile = new File_class("logger.log", "a+");
} }
FileLogHandler::FileLogHandler(const char* aFileName, FileLogHandler::FileLogHandler(const char* aFileName,
...@@ -47,7 +41,7 @@ FileLogHandler::FileLogHandler(const char* aFileName, ...@@ -47,7 +41,7 @@ FileLogHandler::FileLogHandler(const char* aFileName,
m_maxFileSize(maxFileSize), m_maxFileSize(maxFileSize),
m_maxLogEntries(maxLogEntries) m_maxLogEntries(maxLogEntries)
{ {
m_pLogFile = new File(aFileName, "a+"); m_pLogFile = new File_class(aFileName, "a+");
} }
FileLogHandler::~FileLogHandler() FileLogHandler::~FileLogHandler()
...@@ -166,10 +160,10 @@ FileLogHandler::createNewFile() ...@@ -166,10 +160,10 @@ FileLogHandler::createNewFile()
::snprintf(newName, sizeof(newName), ::snprintf(newName, sizeof(newName),
"%s.%d", m_pLogFile->getName(), fileNo++); "%s.%d", m_pLogFile->getName(), fileNo++);
} while (File::exists(newName)); } while (File_class::exists(newName));
m_pLogFile->close(); m_pLogFile->close();
if (!File::rename(m_pLogFile->getName(), newName)) if (!File_class::rename(m_pLogFile->getName(), newName))
{ {
setErrorCode(errno); setErrorCode(errno);
rc = false; rc = false;
...@@ -201,7 +195,7 @@ FileLogHandler::setFilename(const BaseString &filename) { ...@@ -201,7 +195,7 @@ FileLogHandler::setFilename(const BaseString &filename) {
close(); close();
if(m_pLogFile) if(m_pLogFile)
delete m_pLogFile; delete m_pLogFile;
m_pLogFile = new File(filename.c_str(), "a+"); m_pLogFile = new File_class(filename.c_str(), "a+");
open(); open();
return true; return true;
}; };
......
...@@ -17,9 +17,6 @@ ...@@ -17,9 +17,6 @@
#include "LogHandler.hpp" #include "LogHandler.hpp"
#include <NdbTick.h> #include <NdbTick.h>
#include <NdbString.h>
#include <time.h>
// //
// PUBLIC // PUBLIC
......
...@@ -17,8 +17,6 @@ ...@@ -17,8 +17,6 @@
#include "LogHandlerList.hpp" #include "LogHandlerList.hpp"
#include <LogHandler.hpp> #include <LogHandler.hpp>
#include <NdbStdio.h>
#include <ndb_types.h>
// //
// PUBLIC // PUBLIC
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <stdarg.h> #include <ndb_global.h>
#include "Logger.hpp" #include "Logger.hpp"
...@@ -27,12 +27,6 @@ ...@@ -27,12 +27,6 @@
#include <SysLogHandler.hpp> #include <SysLogHandler.hpp>
#endif #endif
#include <NdbStdio.h>
#include <ndb_types.h>
#include <NdbString.h>
#include <assert.h>
// //
// PUBLIC // PUBLIC
// //
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
#include "SysLogHandler.hpp" #include "SysLogHandler.hpp"
#include <syslog.h> #include <syslog.h>
#include <NdbString.h>
// //
// PUBLIC // PUBLIC
......
...@@ -14,6 +14,8 @@ ...@@ -14,6 +14,8 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "LogHandlerListUnitTest.hpp" #include "LogHandlerListUnitTest.hpp"
#include <ConsoleLogHandler.hpp> #include <ConsoleLogHandler.hpp>
...@@ -22,9 +24,6 @@ ...@@ -22,9 +24,6 @@
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <stdio.h>
#include <assert.h>
typedef bool (*TESTFUNC)(const char*); typedef bool (*TESTFUNC)(const char*);
typedef struct typedef struct
{ {
......
...@@ -25,12 +25,8 @@ ...@@ -25,12 +25,8 @@
#endif #endif
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <NdbStdio.h>
#include <NdbMain.h> #include <NdbMain.h>
#include <string.h>
#include <assert.h>
typedef bool (*TESTFUNC)(const char*); typedef bool (*TESTFUNC)(const char*);
typedef struct typedef struct
{ {
......
...@@ -23,9 +23,7 @@ ...@@ -23,9 +23,7 @@
#include <kernel_types.h> #include <kernel_types.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <NdbStdio.h>
#include <ndb_limits.h> #include <ndb_limits.h>
#include <NdbConstant.hpp>
#include <Properties.hpp> #include <Properties.hpp>
/** /**
......
...@@ -14,6 +14,10 @@ ...@@ -14,6 +14,10 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include <ndb_version.h>
#include <sys/stat.h>
#include <ConfigRetriever.hpp> #include <ConfigRetriever.hpp>
#include "LocalConfig.hpp" #include "LocalConfig.hpp"
...@@ -21,21 +25,15 @@ ...@@ -21,21 +25,15 @@
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <NdbTCP.h> #include <NdbTCP.h>
#include <string.h>
#include <NdbStdio.h>
#include <NdbEnv.h> #include <NdbEnv.h>
#include "MgmtErrorReporter.hpp" #include "MgmtErrorReporter.hpp"
#include <uucode.h> #include <uucode.h>
#include <Properties.hpp> #include <Properties.hpp>
#include <stdio.h>
#include <NdbString.h>
#include <sys/stat.h>
#include <socket_io.h> #include <socket_io.h>
#include <NdbConfig.h> #include <NdbConfig.h>
#include <ndb_version.h>
//**************************************************************************** //****************************************************************************
//**************************************************************************** //****************************************************************************
......
...@@ -14,16 +14,13 @@ ...@@ -14,16 +14,13 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "InitConfigFileParser.hpp" #include "InitConfigFileParser.hpp"
#include <string.h>
#include <errno.h>
#include "Config.hpp" #include "Config.hpp"
#include "MgmtErrorReporter.hpp" #include "MgmtErrorReporter.hpp"
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include "ConfigInfo.hpp" #include "ConfigInfo.hpp"
#include <stdarg.h>
#include <ctype.h>
#include <NdbString.h>
const int MAX_LINE_LENGTH = 120; // Max length of line of text in config file const int MAX_LINE_LENGTH = 120; // Max length of line of text in config file
static void trim(char *); static void trim(char *);
......
...@@ -17,7 +17,8 @@ ...@@ -17,7 +17,8 @@
#ifndef InitConfigFileParser_H #ifndef InitConfigFileParser_H
#define InitConfigFileParser_H #define InitConfigFileParser_H
#include <stdio.h> #include <ndb_global.h>
#include <Properties.hpp> #include <Properties.hpp>
class Config; class Config;
......
...@@ -17,10 +17,8 @@ ...@@ -17,10 +17,8 @@
#ifndef LocalConfig_H #ifndef LocalConfig_H
#define LocalConfig_H #define LocalConfig_H
#include <stdlib.h> #include <ndb_global.h>
#include <string.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <NdbStdio.h>
//**************************************************************************** //****************************************************************************
// Description: The class LocalConfig corresponds to the information possible // Description: The class LocalConfig corresponds to the information possible
......
...@@ -14,10 +14,9 @@ ...@@ -14,10 +14,9 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include <NdbConfig.h> #include <NdbConfig.h>
#include <NdbEnv.h> #include <NdbEnv.h>
#include <stdlib.h>
#include <string.h>
const char* const char*
NdbConfig_HomePath(char* buf, int buflen){ NdbConfig_HomePath(char* buf, int buflen){
......
...@@ -15,10 +15,11 @@ ...@@ -15,10 +15,11 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include <NdbMain.h> #include <NdbMain.h>
#include <ConfigRetriever.hpp> #include <ConfigRetriever.hpp>
#include <Properties.hpp> #include <Properties.hpp>
#include <stdlib.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
void usage(const char * prg){ void usage(const char * prg){
......
...@@ -16,8 +16,7 @@ ...@@ -16,8 +16,7 @@
#include <stdio.h> #include <ndb_global.h>
#include <unistd.h>
#include <sys/time.h> #include <sys/time.h>
#include <sys/mman.h> #include <sys/mman.h>
long long getMilli(); long long getMilli();
......
...@@ -17,6 +17,9 @@ ...@@ -17,6 +17,9 @@
#include <ndb_global.h>
#include <sys/mman.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <NdbThread.h> #include <NdbThread.h>
#include <NdbMutex.h> #include <NdbMutex.h>
...@@ -27,13 +30,6 @@ ...@@ -27,13 +30,6 @@
#include <NdbHost.h> #include <NdbHost.h>
#include <NdbMain.h> #include <NdbMain.h>
#include <getarg.h> #include <getarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
#include <sys/time.h>
#include <sys/mman.h>
struct ThreadData struct ThreadData
{ {
......
...@@ -14,14 +14,14 @@ ...@@ -14,14 +14,14 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_common.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <NdbMain.h> #include <NdbMain.h>
#include <ose.h> #include <ose.h>
#include <mms.sig> #include <mms.sig>
#include <mms_err.h> #include <mms_err.h>
#include <string.h>
#include <stdio.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
/** /**
......
...@@ -14,13 +14,13 @@ ...@@ -14,13 +14,13 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include "NdbThread.h" #include "NdbThread.h"
#include <NdbMem.h> #include <NdbMem.h>
#include <NdbMain.h> #include <NdbMain.h>
#include <stdlib.h>
NDB_COMMAND(ndbmem, "ndbmem", "ndbmem", "Test the ndbmem functionality", 4096){ NDB_COMMAND(ndbmem, "ndbmem", "ndbmem", "Test the ndbmem functionality", 4096){
ndbout << "Starting test of NdbMem" << endl; ndbout << "Starting test of NdbMem" << endl;
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
#include "NdbCondition.h" #include "NdbCondition.h"
#include <pthread.h> #include <pthread.h>
#include <assert.h>
#include <sys/types.h> #include <sys/types.h>
#include <malloc.h> #include <malloc.h>
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
#include "NdbMem.h" #include "NdbMem.h"
#include <assert.h>
#if defined NDB_OSE #if defined NDB_OSE
#include <ose.h> #include <ose.h>
...@@ -134,7 +133,6 @@ int NdbMem_MemUnlockAll(){ ...@@ -134,7 +133,6 @@ int NdbMem_MemUnlockAll(){
} }
#else #else
#include <assert.h>
#include <stdlib.h> #include <stdlib.h>
......
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#include <pthread.h> #include <pthread.h>
#include <stdlib.h> #include <stdlib.h>
#include <assert.h>
NdbMutex* NdbMutex_Create(void) NdbMutex* NdbMutex_Create(void)
......
...@@ -14,12 +14,9 @@ ...@@ -14,12 +14,9 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include "NdbOut.hpp" #include <ndb_global.h>
#include <NdbStdio.h>
#include <stdarg.h>
#include <NdbUnistd.h>
#include <string.h>
#include "NdbOut.hpp"
#if defined NDB_SOFTOSE #if defined NDB_SOFTOSE
#include <dbgprintf.h> #include <dbgprintf.h>
......
...@@ -18,7 +18,6 @@ ...@@ -18,7 +18,6 @@
#include "NdbThread.h" #include "NdbThread.h"
#include <pthread.h> #include <pthread.h>
#include <malloc.h> #include <malloc.h>
#include <assert.h>
#include <string.h> #include <string.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
* TODO - Add tests for NdbMem * TODO - Add tests for NdbMem
*/ */
#include <ndb_global.h>
#include "NdbOut.hpp" #include "NdbOut.hpp"
#include "NdbThread.h" #include "NdbThread.h"
...@@ -32,11 +32,6 @@ ...@@ -32,11 +32,6 @@
#include "NdbHost.h" #include "NdbHost.h"
#include "NdbMain.h" #include "NdbMain.h"
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
int TestHasFailed; int TestHasFailed;
int verbose = 0; int verbose = 0;
......
...@@ -15,16 +15,10 @@ ...@@ -15,16 +15,10 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <NdbCondition.h> #include <ndb_global.h>
#include <pthread.h>
#include <assert.h>
#include <sys/types.h>
#if defined NDB_MACOSX
#include <stdlib.h>
#else
#include <malloc.h>
#endif
#include <NdbCondition.h>
#include <NdbThread.h>
#include <NdbMutex.h> #include <NdbMutex.h>
struct NdbCondition struct NdbCondition
......
...@@ -14,28 +14,8 @@ ...@@ -14,28 +14,8 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "NdbDaemon.h" #include "NdbDaemon.h"
#include <assert.h>
#ifdef NDB_LINUX
#include <sys/types.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <fcntl.h>
#include <errno.h>
#endif
#ifdef NDB_SOLARIS
#include <sys/types.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <fcntl.h>
#include <errno.h>
#endif
#define NdbDaemon_ErrorSize 500 #define NdbDaemon_ErrorSize 500
#if defined(NDB_LINUX) || defined(NDB_SOLARIS) #if defined(NDB_LINUX) || defined(NDB_SOLARIS)
......
...@@ -15,9 +15,9 @@ ...@@ -15,9 +15,9 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include "NdbEnv.h" #include <ndb_global.h>
#include <string.h>
#include <stdlib.h> #include <NdbEnv.h>
const char* NdbEnv_GetEnv(const char* name, char * buf, int buflen) const char* NdbEnv_GetEnv(const char* name, char * buf, int buflen)
{ {
......
...@@ -15,14 +15,9 @@ ...@@ -15,14 +15,9 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include "NdbMem.h" #include <ndb_global.h>
#include <assert.h> #include <NdbMem.h>
#include <assert.h>
#include <stdlib.h>
#ifndef NDB_MACOSX
#include <sys/mman.h>
#endif
void NdbMem_Create() void NdbMem_Create()
{ {
......
...@@ -15,11 +15,10 @@ ...@@ -15,11 +15,10 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include "NdbMutex.h" #include <ndb_global.h>
#include <pthread.h> #include <NdbThread.h>
#include <stdlib.h> #include <NdbMutex.h>
#include <assert.h>
NdbMutex* NdbMutex_Create(void) NdbMutex* NdbMutex_Create(void)
{ {
......
...@@ -15,16 +15,10 @@ ...@@ -15,16 +15,10 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "NdbThread.h" #include "NdbThread.h"
#include <pthread.h> #include <pthread.h>
#ifdef NDB_MACOSX
#include <stdlib.h>
#else
#include <malloc.h>
#endif
#include <assert.h>
#include <string.h>
#include <NdbStdio.h>
#define MAX_THREAD_NAME 16 #define MAX_THREAD_NAME 16
......
...@@ -18,7 +18,6 @@ ...@@ -18,7 +18,6 @@
#include <winsock2.h> #include <winsock2.h>
#include <ws2tcpip.h> #include <ws2tcpip.h>
#include <windows.h> #include <windows.h>
#include <assert.h>
#include <sys/types.h> #include <sys/types.h>
#include "NdbCondition.h" #include "NdbCondition.h"
......
...@@ -16,8 +16,6 @@ ...@@ -16,8 +16,6 @@
#include <windows.h> #include <windows.h>
#include <assert.h>
#include <NdbStdio.h>
#include "NdbMem.h" #include "NdbMem.h"
......
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#include <ws2tcpip.h> #include <ws2tcpip.h>
#include <windows.h> #include <windows.h>
#include <time.h> #include <time.h>
#include <assert.h>
#include "NdbMutex.h" #include "NdbMutex.h"
......
...@@ -17,7 +17,6 @@ ...@@ -17,7 +17,6 @@
#include <windows.h> #include <windows.h>
#include <process.h> #include <process.h>
#include <assert.h>
#include "NdbThread.h" #include "NdbThread.h"
......
...@@ -20,7 +20,6 @@ ...@@ -20,7 +20,6 @@
#include "TransporterCallback.hpp" #include "TransporterCallback.hpp"
#include <TransporterRegistry.hpp> #include <TransporterRegistry.hpp>
#include "TransporterInternalDefinitions.hpp" #include "TransporterInternalDefinitions.hpp"
#include <NdbStdio.h>
OSE_Receiver::OSE_Receiver(TransporterRegistry * tr, OSE_Receiver::OSE_Receiver(TransporterRegistry * tr,
int _recBufSize, int _recBufSize,
......
...@@ -23,11 +23,9 @@ ...@@ -23,11 +23,9 @@
#include <NdbMutex.h> #include <NdbMutex.h>
#include <NdbStdio.h>
#include <NdbHost.h> #include <NdbHost.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <time.h> #include <time.h>
#include <assert.h>
OSE_Transporter::OSE_Transporter(int _prioASignalSize, OSE_Transporter::OSE_Transporter(int _prioASignalSize,
int _prioBSignalSize, int _prioBSignalSize,
......
...@@ -14,13 +14,13 @@ ...@@ -14,13 +14,13 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "Packer.hpp" #include "Packer.hpp"
#include <TransporterRegistry.hpp> #include <TransporterRegistry.hpp>
#include <TransporterCallback.hpp> #include <TransporterCallback.hpp>
#include <RefConvert.hpp> #include <RefConvert.hpp>
#include <stdio.h>
Uint32 Uint32
TransporterRegistry::unpack(Uint32 * readPtr, TransporterRegistry::unpack(Uint32 * readPtr,
Uint32 sizeOfData, Uint32 sizeOfData,
......
...@@ -14,17 +14,14 @@ ...@@ -14,17 +14,14 @@
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "SCI_Transporter.hpp" #include "SCI_Transporter.hpp"
#include <NdbStdio.h>
#include <NdbOut.hpp> #include <NdbOut.hpp>
#include <NdbSleep.h> #include <NdbSleep.h>
#include <NdbTick.h> #include <NdbTick.h>
#include <stdlib.h>
#include <NdbTick.h> #include <NdbTick.h>
#if 0
#include <malloc.h>
#include <sys/time.h>
#endif
#include "TransporterInternalDefinitions.hpp" #include "TransporterInternalDefinitions.hpp"
#include <TransporterCallback.hpp> #include <TransporterCallback.hpp>
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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