Fixed bug #646 SDL-1.2
authorSam Lantinga <slouken@libsdl.org>
Tue, 17 Feb 2009 05:25:25 +0000
branchSDL-1.2
changeset 4163bec67d0b6645
parent 4162 3b7fc3416601
child 4164 7a4c511c980a
Fixed bug #646

Description From Pavol Rusnak 2008-11-27 05:51:44 (-) [reply]

src/video/fbcon/SDL_fbvideo.c:283: warning: ordered comparison of pointer with
integer zero

The source code is

if (fgets(line,length,f)<=0)

Suggest replace with

if (fgets(line,length,f) == 0)
src/video/fbcon/SDL_fbvideo.c
     1.1 --- a/src/video/fbcon/SDL_fbvideo.c	Mon Feb 16 22:32:34 2009 +0000
     1.2 +++ b/src/video/fbcon/SDL_fbvideo.c	Tue Feb 17 05:25:25 2009 +0000
     1.3 @@ -280,7 +280,7 @@
     1.4  	/* find a relevant line */
     1.5  	do
     1.6  	{
     1.7 -		if (fgets(line,length,f)<=0)
     1.8 +		if (!fgets(line,length,f))
     1.9  			return 0;
    1.10  		c=line;
    1.11  		while(((*c=='\t')||(*c==' '))&&(*c!=0))