ia64/xen-unstable

changeset 18840:8d5474a5c66b

Avoid warn_unused_result build failure on fgets().
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
author Keir Fraser <keir.fraser@citrix.com>
date Thu Nov 27 12:43:25 2008 +0000 (2008-11-27)
parents 840b761e07c1
children 90ed7af65570
files xen/tools/symbols.c
line diff
     1.1 --- a/xen/tools/symbols.c	Thu Nov 27 11:24:52 2008 +0000
     1.2 +++ b/xen/tools/symbols.c	Thu Nov 27 12:43:25 2008 +0000
     1.3 @@ -81,7 +81,8 @@ static int read_symbol(FILE *in, struct 
     1.4  	if (rc != 3) {
     1.5  		if (rc != EOF) {
     1.6  			/* skip line */
     1.7 -			fgets(str, 500, in);
     1.8 +			if (fgets(str, 500, in) == NULL)
     1.9 +				return -1; /* must check fgets result */
    1.10  		}
    1.11  		return -1;
    1.12  	}