diff --git a/code/ryzom/CMakeModules/nel.cmake b/code/ryzom/CMakeModules/nel.cmake index d6bedfebf..13de31a56 100644 --- a/code/ryzom/CMakeModules/nel.cmake +++ b/code/ryzom/CMakeModules/nel.cmake @@ -75,7 +75,7 @@ MACRO(NL_SETUP_BUILD) SET(NL_RELEASE_CFLAGS "/Ox /Ob2 /Oi /Ot /Oy /GT /GF") SET(NL_RELEASEDEBUG_CFLAGS "/DNL_RELEASE_DEBUG /Ob2 /GF") ELSE(WIN32) - SET(PLATFORM_CFLAGS "-ftemplate-depth-48 -D_REENTRANT -Wall -ansi -W -Wpointer-arith -Wsign-compare -Wno-deprecated-declarations -Wno-multichar -Wno-long-long -Wno-unused") + SET(PLATFORM_CFLAGS "-ftemplate-depth-48 -D_REENTRANT -Wall -ansi -W -Wpointer-arith -Wsign-compare -Wno-deprecated-declarations -Wno-multichar -Wno-long-long -Wno-unused -fno-strict-aliasing") IF(WITH_COVERAGE) SET(PLATFORM_CFLAGS "-fprofile-arcs -ftest-coverage ${PLATFORM_CFLAGS}") ENDIF(WITH_COVERAGE) diff --git a/code/ryzom/common/src/game_share/dyn_chat.cpp b/code/ryzom/common/src/game_share/dyn_chat.cpp index 69469e319..8b1632caa 100644 --- a/code/ryzom/common/src/game_share/dyn_chat.cpp +++ b/code/ryzom/common/src/game_share/dyn_chat.cpp @@ -29,10 +29,10 @@ uint CDynChatSession::_NumSessions = 0; ///////////////////// //================================================================ CDynChatSession::CDynChatSession(CDynChatClient *client, CDynChatChan *channel) - : _Client(client), - _Channel(channel), - StringID(0), - WriteRight(false) + : StringID(0), + WriteRight(false), + _Client(client), + _Channel(channel) { nlassert(client); nlassert(channel); @@ -102,7 +102,7 @@ CDynChatSession::~CDynChatSession() // CDynChatClient // //////////////////// //================================================================ -CDynChatClient::CDynChatClient(const TDataSetRow &client) : _ID(client), _FirstSession(NULL) +CDynChatClient::CDynChatClient(const TDataSetRow &client) : _FirstSession(NULL), _ID(client) { } @@ -136,26 +136,26 @@ CDynChatSession *CDynChatClient::getSession(TChanID chan) const // CDynChatChan // ////////////////// CDynChatChan::CDynChatChan() -: _ID(CEntityId::Unknown), - _FirstSession(NULL), - HistoricSize(0), - _DontBroadcastPlayerInputs(false), - _ForwardPlayerIntputToOwnerService(false), - _UnifyChannel(false), - HideBubble(false) + : HistoricSize(0), + HideBubble(false), + _FirstSession(NULL), + _ID(CEntityId::Unknown), + _DontBroadcastPlayerInputs(false), + _ForwardPlayerIntputToOwnerService(false), + _UnifyChannel(false) { } //================================================================ //CDynChatChan::CDynChatChan(TChanID id) : _ID(id), _FirstSession(NULL), HistoricSize(0) CDynChatChan::CDynChatChan(TChanID id, bool noBroadcast, bool forwardInput, bool unified) - : _ID(id), - _FirstSession(NULL), - HistoricSize(0), - _DontBroadcastPlayerInputs(noBroadcast), - _ForwardPlayerIntputToOwnerService(forwardInput), - _UnifyChannel(unified), - HideBubble(false) + : HistoricSize(0), + HideBubble(false), + _FirstSession(NULL), + _ID(id), + _DontBroadcastPlayerInputs(noBroadcast), + _ForwardPlayerIntputToOwnerService(forwardInput), + _UnifyChannel(unified) { } diff --git a/code/ryzom/common/src/game_share/effect_families.cpp b/code/ryzom/common/src/game_share/effect_families.cpp index 6a6978f83..bc212aa3c 100644 --- a/code/ryzom/common/src/game_share/effect_families.cpp +++ b/code/ryzom/common/src/game_share/effect_families.cpp @@ -214,6 +214,9 @@ namespace EFFECT_FAMILIES case DMGTYPE::POISON : return DebuffResistPoison; case DMGTYPE::ELECTRICITY : return DebuffResistElectricity; case DMGTYPE::SHOCK : return DebuffResistSchock; + default: + return Unknown; + break; } return Unknown; } @@ -229,6 +232,9 @@ namespace EFFECT_FAMILIES case DMGTYPE::POISON : return CombatDoTPoison; case DMGTYPE::ELECTRICITY : return CombatDoTElectricity; case DMGTYPE::SHOCK : return CombatDoTShock; + default: + return Unknown; + break; } return Unknown; } diff --git a/code/ryzom/common/src/game_share/mirror.cpp b/code/ryzom/common/src/game_share/mirror.cpp index 5eebf5043..1317ed15e 100644 --- a/code/ryzom/common/src/game_share/mirror.cpp +++ b/code/ryzom/common/src/game_share/mirror.cpp @@ -1485,17 +1485,17 @@ void CMirror::changeValue( const NLMISC::CEntityId& entityId, const std::string& */ CMirror::CMirror() : _PendingEntityTypesRanges(0), - _MirrorAllReady(false), _ReadyL1Callback(NULL), _NotificationCallback(NULL), + _UserSyncCallback(NULL), + _MirrorAllReady(false), _MirrorGotReadyLevel1(false), _MirrorGotReadyLevel2(false), _ListOfOtherPropertiesReceived(false), _AwaitingAllMirrorsOnline(false), _IsExecutingSynchronizedCode(false), - MonitoredEntity(CEntityId::Unknown), _ClosureRequested(false), - _UserSyncCallback(NULL) + MonitoredEntity(CEntityId::Unknown) { nlassert( ! MirrorInstance ); // singleton check MirrorInstance = this; diff --git a/code/ryzom/common/src/game_share/mode_and_behaviour.h b/code/ryzom/common/src/game_share/mode_and_behaviour.h index ff07a69a6..15466fe8a 100644 --- a/code/ryzom/common/src/game_share/mode_and_behaviour.h +++ b/code/ryzom/common/src/game_share/mode_and_behaviour.h @@ -453,7 +453,7 @@ namespace MBEHAV sint16 DeltaHP; uint16 Unused; /// Keep it, used to make the class size = 64 bits (sizeof(CBehaviour) MUST return 8 (bytes)) - inline CBehaviour() : Behaviour(UNKNOWN_BEHAVIOUR), Data(0), Data2(0), DeltaHP(0), Unused(0) {} + inline CBehaviour() : Data(0), Data2(0), Behaviour(UNKNOWN_BEHAVIOUR), DeltaHP(0), Unused(0) {} inline CBehaviour( EBehaviour behaviour ) { diff --git a/code/ryzom/common/src/game_share/utils.h b/code/ryzom/common/src/game_share/utils.h index d709dbd64..f985609fe 100644 --- a/code/ryzom/common/src/game_share/utils.h +++ b/code/ryzom/common/src/game_share/utils.h @@ -95,7 +95,7 @@ inline ucstring capitalize(const ucstring & s) nldebug("Dumping callstack :"); \ for (uint i=0; i