Skip to content

Commit

Permalink
test: Fix for negative int that was now a size_t (thanks, Ozkan!).
Browse files Browse the repository at this point in the history
Fixes Bugzilla #3787.
  • Loading branch information
icculus committed Aug 29, 2017
1 parent 21e32ba commit 4fc0163
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/testautomation_sdltest.c
Expand Up @@ -35,6 +35,7 @@ sdltest_generateRunSeed(void *arg)
{
char* result;
size_t i, l;
int j;

for (i = 1; i <= 10; i += 3) {
result = SDLTest_GenerateRunSeed((const int)i);
Expand All @@ -48,8 +49,8 @@ sdltest_generateRunSeed(void *arg)
}

/* Negative cases */
for (i = -2; i <= 0; i++) {
result = SDLTest_GenerateRunSeed((const int)i);
for (j = -2; j <= 0; i++) {
result = SDLTest_GenerateRunSeed((const int)j);
SDLTest_AssertPass("Call to SDLTest_GenerateRunSeed()");
SDLTest_AssertCheck(result == NULL, "Verify returned value is not NULL");
}
Expand Down

0 comments on commit 4fc0163

Please sign in to comment.