diff options
author | frosch <frosch@openttd.org> | 2017-08-20 21:04:21 +0000 |
---|---|---|
committer | frosch <frosch@openttd.org> | 2017-08-20 21:04:21 +0000 |
commit | 062c736437cf019bd781d8b34a538bb7ba88d286 (patch) | |
tree | 3b9ef50bc9b1fd4fdee9980fd7d9cbb50d748e8f /src | |
parent | a6e7f1142bff2aa27ddeaa5e4cbd44649fc11f46 (diff) | |
download | openttd-062c736437cf019bd781d8b34a538bb7ba88d286.tar.xz |
(svn r27896) -Fix: some warnings
Diffstat (limited to 'src')
-rw-r--r-- | src/3rdparty/squirrel/squirrel/sqvm.cpp | 2 | ||||
-rw-r--r-- | src/fios.cpp | 2 | ||||
-rw-r--r-- | src/pathfinder/npf/npf.cpp | 1 |
3 files changed, 3 insertions, 2 deletions
diff --git a/src/3rdparty/squirrel/squirrel/sqvm.cpp b/src/3rdparty/squirrel/squirrel/sqvm.cpp index a738244ba..c66c4aca5 100644 --- a/src/3rdparty/squirrel/squirrel/sqvm.cpp +++ b/src/3rdparty/squirrel/squirrel/sqvm.cpp @@ -1102,7 +1102,7 @@ exception_trap: _lasterror = currerror; return false; } - assert(0); + NOT_REACHED(); } bool SQVM::CreateClassInstance(SQClass *theclass, SQObjectPtr &inst, SQObjectPtr &constructor) diff --git a/src/fios.cpp b/src/fios.cpp index 0d30e0965..5e78fb1b4 100644 --- a/src/fios.cpp +++ b/src/fios.cpp @@ -77,7 +77,7 @@ void FileList::BuildFileList(AbstractFileType abstract_filetype, SaveLoadOperati { this->Clear(); - assert(fop == SLO_LOAD || SLO_SAVE); + assert(fop == SLO_LOAD || fop == SLO_SAVE); switch (abstract_filetype) { case FT_NONE: break; diff --git a/src/pathfinder/npf/npf.cpp b/src/pathfinder/npf/npf.cpp index ebaf2ac57..1867b4b18 100644 --- a/src/pathfinder/npf/npf.cpp +++ b/src/pathfinder/npf/npf.cpp @@ -1236,6 +1236,7 @@ bool NPFTrainFindNearestSafeTile(const Train *v, TileIndex tile, Trackdir trackd /* We set this in case the target is also the start tile, we will just * return a not found then */ start1.user_data[NPF_TRACKDIR_CHOICE] = INVALID_TRACKDIR; + start1.user_data[NPF_NODE_FLAGS] = 0; start1.direction = trackdir; NPFSetFlag(&start1, NPF_FLAG_IGNORE_RESERVED, true); |