Fix various compiler and valgrind warnings, including:
authorDataBeaver <tdb@tdb.fi>
Sat, 8 Jan 2011 11:36:42 +0000 (11:36 +0000)
committerDataBeaver <tdb@tdb.fi>
Sat, 8 Jan 2011 11:36:42 +0000 (11:36 +0000)
commit04605eaa23f403af8412174db79fedc0b3f09e09
tree9031fb392f8dc610ca0e7e651b617aa91cd6ad8d
parent3b57ac73c8be4b5806eb87d0ebaa103d53e066d2
Fix various compiler and valgrind warnings, including:
- compare CString::find result against CString::npos, not -1
- use CString::size_type to hold string indices, not int
- fix other signed vs unsigned comparisons as well
- parentheses in expressions with mixed and/or operators
- braces around ifs containing other ifs and elses
- make sure variables are initialized before using
- #pragma warning is MSVC-specific
- fix an invalid printf format string
- string literals are const

git-svn-id: https://openitg.svn.sourceforge.net/svnroot/openitg/branches/dev@865 83fadc84-e282-4d84-a09a-c4228d6ae7e5
33 files changed:
src/BGAnimationLayer.cpp
src/BitmapText.cpp
src/CodeDetector.cpp
src/Course.cpp
src/DifficultyIcon.cpp
src/GameManager.cpp
src/GameState.cpp
src/GradeDisplay.cpp
src/GraphDisplay.cpp
src/LinkedOptionsMenu.cpp
src/ModelTypes.cpp
src/NetworkSyncManager.cpp
src/NoteDataUtil.cpp
src/NotesLoaderBMS.cpp
src/NotesLoaderDWI.cpp
src/NotesLoaderKSF.cpp
src/RageBitmapTexture.cpp
src/RageFileDriverCrypt_ITG2.cpp
src/RageInputDevice.h
src/RageSound.cpp
src/RageUtil.cpp
src/ScreenEndlessBreak.cpp
src/ScreenGameplay.cpp
src/ScreenJukebox.cpp
src/ScreenNetSelectMusic.cpp
src/ScreenSelectMode.cpp
src/ScreenSelectMusic.cpp
src/Song.cpp
src/Sprite.cpp
src/UnlockManager.cpp
src/UserPackManager.cpp
src/arch/Lights/LightsDriver_Dynamic.cpp
src/archutils/Unix/X11Helper.cpp