ASan kakkoii desu
This commit is contained in:
parent
6b8144134d
commit
4be55967f4
5 changed files with 9 additions and 15 deletions
|
|
@ -538,7 +538,7 @@ consvar_t cv_votetime = CVAR_INIT ("votetime", "20", CV_NETVAR, votetime_cons_t,
|
|||
|
||||
consvar_t cv_gravity = CVAR_INIT ("gravity", "0.8", CV_RESTRICT|CV_FLOAT|CV_CALL, NULL, Gravity_OnChange); // change DEFAULT_GRAVITY if you change this
|
||||
|
||||
static CV_PossibleValue_t soundtest_cons_t[] = {{0, "MIN"}, {NUMSFX, "MAX"}};
|
||||
static CV_PossibleValue_t soundtest_cons_t[] = {{0, "MIN"}, {NUMSFX, "MAX"}, {0, NULL}};
|
||||
consvar_t cv_soundtest = CVAR_INIT ("soundtest", "0", CV_CALL, soundtest_cons_t, SoundTest_OnChange);
|
||||
|
||||
static CV_PossibleValue_t minitimelimit_cons_t[] = {{15, "MIN"}, {9999, "MAX"}, {0, NULL}};
|
||||
|
|
|
|||
|
|
@ -153,7 +153,7 @@ typedef enum
|
|||
levellist_mode_t levellistmode = LLM_CREATESERVER;
|
||||
UINT8 maplistoption = 0;
|
||||
|
||||
static char joystickInfo[MAXGAMEPADS][29];
|
||||
static char joystickInfo[MAXGAMEPADS+1][29];
|
||||
|
||||
INT16 startmap; // Mario, NiGHTS, or just a plain old normal game?
|
||||
|
||||
|
|
@ -2806,8 +2806,6 @@ static void M_PrepareLevelSelect(void)
|
|||
//
|
||||
boolean M_CanShowLevelInList(INT32 mapnum, INT32 gt)
|
||||
{
|
||||
UINT32 tolflag = G_TOLFlag(gt);
|
||||
|
||||
// Random map!
|
||||
if (mapnum == -1)
|
||||
return (levellistmode == LLM_CREATESERVER);
|
||||
|
|
@ -2835,7 +2833,7 @@ boolean M_CanShowLevelInList(INT32 mapnum, INT32 gt)
|
|||
return false; // not unlocked
|
||||
|
||||
// Check for TOL
|
||||
if (!(mapheaderinfo[mapnum]->typeoflevel & tolflag))
|
||||
if (gt >= 0 && !(mapheaderinfo[mapnum]->typeoflevel & G_TOLFlag(gt)))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
|
|
@ -4433,7 +4431,7 @@ INT32 MR_PlaybackAdjustView(INT32 choice)
|
|||
M_IsItemOn(MN_PLAYBACK, "VIEW3") ? 3 :
|
||||
M_IsItemOn(MN_PLAYBACK, "VIEW4") ? 4 : -1;
|
||||
|
||||
if (splitnum < 1 && splitnum > 4)
|
||||
if (splitnum < 1 || splitnum > 4)
|
||||
return false;
|
||||
|
||||
G_AdjustView(splitnum, (choice > 0) ? 1 : -1, true);
|
||||
|
|
|
|||
|
|
@ -2193,14 +2193,14 @@ const char *M_TokenizerRead(UINT32 i)
|
|||
M_DetectComment(&tokenizerStartPos);
|
||||
|
||||
// Find the first non-whitespace char, or else the end of the string trying
|
||||
while ((tokenizerInput[tokenizerStartPos] == ' '
|
||||
while (tokenizerStartPos < tokenizerInputLength
|
||||
&& (tokenizerInput[tokenizerStartPos] == ' '
|
||||
|| tokenizerInput[tokenizerStartPos] == '\t'
|
||||
|| tokenizerInput[tokenizerStartPos] == '\r'
|
||||
|| tokenizerInput[tokenizerStartPos] == '\n'
|
||||
|| tokenizerInput[tokenizerStartPos] == '\0'
|
||||
|| tokenizerInput[tokenizerStartPos] == '=' || tokenizerInput[tokenizerStartPos] == ';' // UDMF TEXTMAP.
|
||||
|| tokenizerInComment != 0)
|
||||
&& tokenizerStartPos < tokenizerInputLength)
|
||||
|| tokenizerInComment != 0))
|
||||
{
|
||||
// Try to detect comment endings now
|
||||
if (tokenizerInComment == 1 && tokenizerInput[tokenizerStartPos] == '\n')
|
||||
|
|
|
|||
|
|
@ -1547,7 +1547,7 @@ static boolean TextmapCount(size_t size, boolean patch)
|
|||
numsectors = 0;
|
||||
}
|
||||
|
||||
while (M_TokenizerGetEndPos() < size)
|
||||
for (; tkn && M_TokenizerGetEndPos() < size; tkn = M_TokenizerRead(0))
|
||||
{
|
||||
// Avoid anything inside bracketed stuff, only look for external keywords.
|
||||
if (brackets)
|
||||
|
|
@ -1572,10 +1572,6 @@ static boolean TextmapCount(size_t size, boolean patch)
|
|||
TextmapStorePos(§orBlocks, &numsectors);
|
||||
else
|
||||
CONS_Alert(CONS_NOTICE, "Unknown field '%s'.\n", tkn);
|
||||
|
||||
tkn = M_TokenizerRead(0);
|
||||
if (!tkn)
|
||||
break;
|
||||
}
|
||||
|
||||
if (brackets)
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ void S_InitRuntimeSounds (void)
|
|||
if (i >= sfx_freeslot0)
|
||||
{
|
||||
value = (i+1) - sfx_freeslot0;
|
||||
sprintf(soundname, value < 1000 ? "fre%03d" : "fr%d", value);
|
||||
sprintf(soundname, value < 1000 ? "fre%03d" : value < 10000 ? "fr%d" : "f%d", value);
|
||||
strcpy(soundnames[i], soundname);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue