mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Making 4.1 tree compile with -ansi -pedantic
include/raid.h: Fixing compile-time warning: pragma interface is not supported in C, let's move it to C++ part of the header. ndb/include/kernel/signaldata/CreateEvnt.hpp: - remove extra erroneous ; from ends of function definitions ndb/include/kernel/signaldata/PackedSignal.hpp: - remove extra erroneous ; from ends of function definitions ndb/include/kernel/signaldata/SumaImpl.hpp: - remove extra erroneous ; from ends of function definitions ndb/src/common/debugger/signaldata/DictTabInfo.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/common/debugger/signaldata/NFCompleteRep.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/common/logger/FileLogHandler.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/backup/BackupInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dbacc/DbaccInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dbdict/Dbdict.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dbdih/DbdihInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dblqh/DblqhInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dbtc/DbtcInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dbtup/DbtupGen.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dbtux/Dbtux.hpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dbtux/DbtuxGen.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/dbutil/DbUtil.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/grep/GrepInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/ndbcntr/NdbcntrInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/ndbfs/Ndbfs.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/ndbfs/VoidFs.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/qmgr/QmgrInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/suma/Suma.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/suma/SumaInit.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/kernel/blocks/trix/Trix.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/mgmsrv/MgmtSrvr.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/ndbapi/NdbEventOperation.cpp: - remove extra erroneous ; from ends of function definitions ndb/src/ndbapi/NdbScanFilter.cpp: - remove extra erroneous ; from ends of function definitions ndb/tools/restore/Restore.cpp: - remove extra erroneous ; from ends of function definitions sql/item_create.h: - remove extra erroneous ; sql/sql_cache.cc: - remove extra erroneous ; tests/client_test.c: - fix -pedantic warning
This commit is contained in:
@ -32,9 +32,6 @@ C_MODE_END
|
||||
#endif
|
||||
#if defined(USE_RAID)
|
||||
|
||||
#ifdef __GNUC__
|
||||
#pragma interface /* gcc class implementation */
|
||||
#endif
|
||||
#include "my_dir.h"
|
||||
|
||||
/* Trap all occurences of my_...() in source and use our wrapper around this function */
|
||||
@ -92,6 +89,10 @@ extern "C" {
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
#ifdef __GNUC__
|
||||
#pragma interface /* gcc class implementation */
|
||||
#endif
|
||||
|
||||
class RaidName {
|
||||
public:
|
||||
RaidName(const char *FileName);
|
||||
|
@ -475,14 +475,14 @@ struct CreateEvntRef {
|
||||
}
|
||||
};
|
||||
inline bool CreateEvntRef::isTemporary() const
|
||||
{ return (errorCode & CreateEvntRef::Temporary) > 0; };
|
||||
{ return (errorCode & CreateEvntRef::Temporary) > 0; }
|
||||
inline void CreateEvntRef::setTemporary()
|
||||
{ errorCode |= CreateEvntRef::Temporary; };
|
||||
{ errorCode |= CreateEvntRef::Temporary; }
|
||||
inline CreateEvntRef::ErrorCode CreateEvntRef::setTemporary(ErrorCode ec)
|
||||
{ return (CreateEvntRef::ErrorCode)
|
||||
(errorCode = ((Uint32) ec | (Uint32)CreateEvntRef::Temporary)); };
|
||||
(errorCode = ((Uint32) ec | (Uint32)CreateEvntRef::Temporary)); }
|
||||
inline CreateEvntRef::ErrorCode CreateEvntRef::makeTemporary(ErrorCode ec)
|
||||
{ return (CreateEvntRef::ErrorCode)
|
||||
( (Uint32) ec | (Uint32)CreateEvntRef::Temporary ); };
|
||||
( (Uint32) ec | (Uint32)CreateEvntRef::Temporary ); }
|
||||
|
||||
#endif
|
||||
|
@ -38,6 +38,6 @@ class PackedSignal {
|
||||
};
|
||||
|
||||
inline
|
||||
Uint32 PackedSignal::getSignalType(Uint32 data) { return data >> 28; };
|
||||
Uint32 PackedSignal::getSignalType(Uint32 data) { return data >> 28; }
|
||||
|
||||
#endif
|
||||
|
@ -159,12 +159,12 @@ public:
|
||||
Uint32 subscriberRef;
|
||||
};
|
||||
inline bool SubStartRef::isTemporary() const
|
||||
{ return (errorCode & SubStartRef::Temporary) > 0; };
|
||||
{ return (errorCode & SubStartRef::Temporary) > 0; }
|
||||
inline void SubStartRef::setTemporary()
|
||||
{ errorCode |= SubStartRef::Temporary; };
|
||||
{ errorCode |= SubStartRef::Temporary; }
|
||||
inline SubStartRef::ErrorCode SubStartRef::setTemporary(ErrorCode ec)
|
||||
{ return (SubStartRef::ErrorCode)
|
||||
(errorCode = ((Uint32) ec | (Uint32)SubStartRef::Temporary)); };
|
||||
(errorCode = ((Uint32) ec | (Uint32)SubStartRef::Temporary)); }
|
||||
|
||||
class SubStartConf {
|
||||
/**
|
||||
@ -239,12 +239,12 @@ public:
|
||||
};
|
||||
};
|
||||
inline bool SubStopRef::isTemporary() const
|
||||
{ return (errorCode & SubStopRef::Temporary) > 0; };
|
||||
{ return (errorCode & SubStopRef::Temporary) > 0; }
|
||||
inline void SubStopRef::setTemporary()
|
||||
{ errorCode |= SubStopRef::Temporary; };
|
||||
{ errorCode |= SubStopRef::Temporary; }
|
||||
inline SubStopRef::ErrorCode SubStopRef::setTemporary(ErrorCode ec)
|
||||
{ return (SubStopRef::ErrorCode)
|
||||
(errorCode = ((Uint32) ec | (Uint32)SubStopRef::Temporary)); };
|
||||
(errorCode = ((Uint32) ec | (Uint32)SubStopRef::Temporary)); }
|
||||
|
||||
class SubStopConf {
|
||||
/**
|
||||
@ -515,12 +515,12 @@ public:
|
||||
};
|
||||
};
|
||||
inline bool SubRemoveRef::isTemporary() const
|
||||
{ return (err & SubRemoveRef::Temporary) > 0; };
|
||||
{ return (err & SubRemoveRef::Temporary) > 0; }
|
||||
inline void SubRemoveRef::setTemporary()
|
||||
{ err |= SubRemoveRef::Temporary; };
|
||||
{ err |= SubRemoveRef::Temporary; }
|
||||
inline SubRemoveRef::ErrorCode SubRemoveRef::setTemporary(ErrorCode ec)
|
||||
{ return (SubRemoveRef::ErrorCode)
|
||||
(errorCode = ((Uint32) ec | (Uint32)SubRemoveRef::Temporary)); };
|
||||
(errorCode = ((Uint32) ec | (Uint32)SubRemoveRef::Temporary)); }
|
||||
|
||||
class SubRemoveConf {
|
||||
/**
|
||||
|
@ -152,4 +152,4 @@ DictTabInfo::Attribute::init(){
|
||||
AttributeExtLength = 0,
|
||||
AttributeAutoIncrement = false;
|
||||
memset(AttributeDefaultValue, 0, sizeof(AttributeDefaultValue));//AttributeDefaultValue[0] = 0;
|
||||
};
|
||||
}
|
||||
|
@ -41,4 +41,4 @@ printNF_COMPLETE_REP(FILE * output,
|
||||
sig->from);
|
||||
|
||||
return true;
|
||||
};
|
||||
}
|
||||
|
@ -198,7 +198,7 @@ FileLogHandler::setFilename(const BaseString &filename) {
|
||||
m_pLogFile = new File_class(filename.c_str(), "a+");
|
||||
open();
|
||||
return true;
|
||||
};
|
||||
}
|
||||
|
||||
bool
|
||||
FileLogHandler::setMaxSize(const BaseString &size) {
|
||||
@ -214,7 +214,7 @@ FileLogHandler::setMaxSize(const BaseString &size) {
|
||||
m_maxFileSize = val;
|
||||
|
||||
return true;
|
||||
};
|
||||
}
|
||||
|
||||
bool
|
||||
FileLogHandler::setMaxFiles(const BaseString &files) {
|
||||
@ -225,7 +225,7 @@ FileLogHandler::setMaxFiles(const BaseString &files) {
|
||||
m_maxNoFiles = val;
|
||||
|
||||
return true;
|
||||
};
|
||||
}
|
||||
|
||||
bool
|
||||
FileLogHandler::checkParams() {
|
||||
|
@ -205,7 +205,7 @@ Backup::~Backup()
|
||||
{
|
||||
}
|
||||
|
||||
BLOCK_FUNCTIONS(Backup);
|
||||
BLOCK_FUNCTIONS(Backup)
|
||||
|
||||
template class ArrayPool<Backup::Page32>;
|
||||
template class ArrayPool<Backup::Attribute>;
|
||||
|
@ -1110,7 +1110,7 @@ Cmvmi::execDUMP_STATE_ORD(Signal* signal)
|
||||
}//Cmvmi::execDUMP_STATE_ORD()
|
||||
|
||||
|
||||
BLOCK_FUNCTIONS(Cmvmi);
|
||||
BLOCK_FUNCTIONS(Cmvmi)
|
||||
|
||||
static Uint32 g_print;
|
||||
static LinearSectionPtr g_test[3];
|
||||
|
@ -264,4 +264,4 @@ Dbacc::~Dbacc()
|
||||
|
||||
}//Dbacc::~Dbacc()
|
||||
|
||||
BLOCK_FUNCTIONS(Dbacc);
|
||||
BLOCK_FUNCTIONS(Dbacc)
|
||||
|
@ -1192,7 +1192,7 @@ Dbdict::~Dbdict()
|
||||
{
|
||||
}//Dbdict::~Dbdict()
|
||||
|
||||
BLOCK_FUNCTIONS(Dbdict);
|
||||
BLOCK_FUNCTIONS(Dbdict)
|
||||
|
||||
void Dbdict::initCommonData()
|
||||
{
|
||||
|
@ -314,7 +314,7 @@ Dbdih::~Dbdih()
|
||||
|
||||
}//Dbdih::~Dbdih()
|
||||
|
||||
BLOCK_FUNCTIONS(Dbdih);
|
||||
BLOCK_FUNCTIONS(Dbdih)
|
||||
|
||||
|
||||
|
||||
|
@ -454,5 +454,5 @@ Dblqh::~Dblqh()
|
||||
ctcNodeFailrecFileSize);
|
||||
}//Dblqh::~Dblqh()
|
||||
|
||||
BLOCK_FUNCTIONS(Dblqh);
|
||||
BLOCK_FUNCTIONS(Dblqh)
|
||||
|
||||
|
@ -365,5 +365,5 @@ Dbtc::~Dbtc()
|
||||
capiConnectFilesize);
|
||||
}//Dbtc::~Dbtc()
|
||||
|
||||
BLOCK_FUNCTIONS(Dbtc);
|
||||
BLOCK_FUNCTIONS(Dbtc)
|
||||
|
||||
|
@ -215,7 +215,7 @@ Dbtup::~Dbtup()
|
||||
|
||||
}//Dbtup::~Dbtup()
|
||||
|
||||
BLOCK_FUNCTIONS(Dbtup);
|
||||
BLOCK_FUNCTIONS(Dbtup)
|
||||
|
||||
/* **************************************************************** */
|
||||
/* ---------------------------------------------------------------- */
|
||||
|
@ -1066,7 +1066,7 @@ Dbtux::Index::Index() :
|
||||
m_fragId[i] = ZNIL;
|
||||
m_fragPtrI[i] = RNIL;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
// Dbtux::Frag
|
||||
|
||||
@ -1103,7 +1103,7 @@ Dbtux::FragOp::FragOp() :
|
||||
m_fragNo(ZNIL),
|
||||
m_numAttrsRecvd(ZNIL)
|
||||
{
|
||||
};
|
||||
}
|
||||
|
||||
// Dbtux::NodeHandle
|
||||
|
||||
|
@ -293,4 +293,4 @@ Dbtux::copyAttrs(const Frag& frag, ConstData data1, Data data2, unsigned maxlen2
|
||||
#endif
|
||||
}
|
||||
|
||||
BLOCK_FUNCTIONS(Dbtux);
|
||||
BLOCK_FUNCTIONS(Dbtux)
|
||||
|
@ -158,7 +158,7 @@ DbUtil::~DbUtil()
|
||||
{
|
||||
}
|
||||
|
||||
BLOCK_FUNCTIONS(DbUtil);
|
||||
BLOCK_FUNCTIONS(DbUtil)
|
||||
|
||||
void
|
||||
DbUtil::releasePrepare(PreparePtr prepPtr) {
|
||||
|
@ -132,7 +132,7 @@ Grep::~Grep()
|
||||
{
|
||||
}
|
||||
|
||||
BLOCK_FUNCTIONS(Grep);
|
||||
BLOCK_FUNCTIONS(Grep)
|
||||
|
||||
Grep::PSPart::PSPart(Grep * sb) :
|
||||
BlockComponent(sb),
|
||||
|
@ -114,4 +114,4 @@ Ndbcntr::~Ndbcntr()
|
||||
|
||||
}//Ndbcntr::~Ndbcntr()
|
||||
|
||||
BLOCK_FUNCTIONS(Ndbcntr);
|
||||
BLOCK_FUNCTIONS(Ndbcntr)
|
||||
|
@ -1010,7 +1010,7 @@ Ndbfs::execDUMP_STATE_ORD(Signal* signal)
|
||||
|
||||
|
||||
|
||||
BLOCK_FUNCTIONS(Ndbfs);
|
||||
BLOCK_FUNCTIONS(Ndbfs)
|
||||
|
||||
template class Vector<AsyncFile*>;
|
||||
template class Vector<OpenFiles::OpenFileItem>;
|
||||
|
@ -196,5 +196,5 @@ VoidFs::execDUMP_STATE_ORD(Signal* signal)
|
||||
|
||||
|
||||
|
||||
BLOCK_FUNCTIONS(VoidFs);
|
||||
BLOCK_FUNCTIONS(VoidFs)
|
||||
|
||||
|
@ -100,4 +100,4 @@ Qmgr::~Qmgr()
|
||||
}//Qmgr::~Qmgr()
|
||||
|
||||
|
||||
BLOCK_FUNCTIONS(Qmgr);
|
||||
BLOCK_FUNCTIONS(Qmgr)
|
||||
|
@ -3553,7 +3553,7 @@ Suma::Restart::Restart(Suma& s) : suma(s) {
|
||||
c_okToStart[i] = false;
|
||||
c_waitingToStart[i] = false;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
void
|
||||
Suma::Restart::resetNode(Uint32 sumaRef)
|
||||
|
@ -188,6 +188,6 @@ Suma::~Suma()
|
||||
{
|
||||
}
|
||||
|
||||
BLOCK_FUNCTIONS(Suma);
|
||||
BLOCK_FUNCTIONS(SumaParticipant);
|
||||
BLOCK_FUNCTIONS(Suma)
|
||||
BLOCK_FUNCTIONS(SumaParticipant)
|
||||
|
||||
|
@ -962,6 +962,6 @@ void Trix::checkParallelism(Signal* signal, SubscriptionRecord* subRec)
|
||||
}
|
||||
}
|
||||
|
||||
BLOCK_FUNCTIONS(Trix);
|
||||
BLOCK_FUNCTIONS(Trix)
|
||||
|
||||
template void append(DataBuffer<15>&,SegmentedSectionPtr,SectionSegmentPool&);
|
||||
|
@ -130,7 +130,7 @@ MgmtSrvr::signalRecvThreadRun()
|
||||
(this->*handler->function)(signal);
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
EventLogger g_EventLogger;
|
||||
|
@ -121,5 +121,5 @@ NdbEventOperation::wait(void *p, int aMillisecondNumber)
|
||||
}
|
||||
|
||||
NdbEventOperation::NdbEventOperation(NdbEventOperationImpl& impl)
|
||||
: m_impl(impl) {};
|
||||
: m_impl(impl) {}
|
||||
|
||||
|
@ -397,7 +397,7 @@ NdbScanFilterImpl::cond_col_const(Interpreter::BinaryCondition op,
|
||||
(m_operation->* branch)(4, 5, m_current.m_ownLabel);
|
||||
|
||||
return 0;
|
||||
};
|
||||
}
|
||||
|
||||
int
|
||||
NdbScanFilter::eq(int AttrId, Uint32 value){
|
||||
@ -478,7 +478,7 @@ NdbScanFilterImpl::cond_col(Interpreter::UnaryCondition op, Uint32 AttrId){
|
||||
Branch1 branch = table2[op].m_branches[m_current.m_group];
|
||||
(m_operation->* branch)(AttrId, m_current.m_ownLabel);
|
||||
return 0;
|
||||
};
|
||||
}
|
||||
|
||||
int
|
||||
NdbScanFilter::isnull(int AttrId){
|
||||
|
@ -260,16 +260,16 @@ TupleS & TupleS::operator=(const TupleS& tuple)
|
||||
memcpy(allAttrData, tuple.allAttrData, getNoOfAttributes()*sizeof(AttributeData));
|
||||
|
||||
return *this;
|
||||
};
|
||||
}
|
||||
int TupleS::getNoOfAttributes() const {
|
||||
if (m_currentTable == 0)
|
||||
return 0;
|
||||
return m_currentTable->getNoOfAttributes();
|
||||
};
|
||||
}
|
||||
|
||||
TableS * TupleS::getTable() const {
|
||||
return m_currentTable;
|
||||
};
|
||||
}
|
||||
|
||||
const AttributeDesc * TupleS::getDesc(int i) const {
|
||||
return m_currentTable->allAttributesDesc[i];
|
||||
@ -277,7 +277,7 @@ const AttributeDesc * TupleS::getDesc(int i) const {
|
||||
|
||||
AttributeData * TupleS::getData(int i) const{
|
||||
return &(allAttrData[i]);
|
||||
};
|
||||
}
|
||||
|
||||
bool
|
||||
TupleS::prepareRecord(TableS & tab){
|
||||
|
@ -87,7 +87,7 @@ Item *create_func_soundex(Item* a);
|
||||
Item *create_func_space(Item *);
|
||||
Item *create_func_sqrt(Item* a);
|
||||
Item *create_func_strcmp(Item* a, Item *b);
|
||||
Item *create_func_tan(Item* a);;
|
||||
Item *create_func_tan(Item* a);
|
||||
Item *create_func_time_format(Item *a, Item *b);
|
||||
Item *create_func_time_to_sec(Item* a);
|
||||
Item *create_func_to_days(Item* a);
|
||||
|
@ -374,7 +374,7 @@ inline Query_cache_block * Query_cache_block_table::block()
|
||||
return (Query_cache_block *)(((byte*)this) -
|
||||
ALIGN_SIZE(sizeof(Query_cache_block_table)*n) -
|
||||
ALIGN_SIZE(sizeof(Query_cache_block)));
|
||||
};
|
||||
}
|
||||
|
||||
/*****************************************************************************
|
||||
Query_cache_block method(s)
|
||||
|
@ -11320,7 +11320,7 @@ static void test_bug4172()
|
||||
MYSQL_ROW row;
|
||||
int rc;
|
||||
char f[100], d[100], e[100];
|
||||
long f_len, d_len, e_len;
|
||||
ulong f_len, d_len, e_len;
|
||||
|
||||
myheader("test_bug4172");
|
||||
|
||||
@ -11411,8 +11411,8 @@ static void test_conversion()
|
||||
|
||||
mysql_stmt_bind_param(stmt, bind);
|
||||
|
||||
buff[0]= 0xC3;
|
||||
buff[1]= 0xA0;
|
||||
buff[0]= (uchar) 0xC3;
|
||||
buff[1]= (uchar) 0xA0;
|
||||
length= 2;
|
||||
|
||||
rc= mysql_stmt_execute(stmt);
|
||||
|
Reference in New Issue
Block a user