From: Dr. Stephen Henson Date: Sun, 4 Oct 2009 14:04:14 +0000 (+0000) Subject: Prevent ignored return value warning X-Git-Tag: OpenSSL_1_0_0-beta4~49 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e6714faffbdfc551ab8b2a50954519dff4bc7b15;p=openssl Prevent ignored return value warning --- diff --git a/crypto/bio/bss_file.c b/crypto/bio/bss_file.c index 480208a315..a85ac209f0 100644 --- a/crypto/bio/bss_file.c +++ b/crypto/bio/bss_file.c @@ -403,11 +403,18 @@ static int MS_CALLBACK file_gets(BIO *bp, char *buf, int size) buf[0]='\0'; if (bp->flags&BIO_FLAGS_UPLINK) - UP_fgets(buf,size,bp->ptr); + { + if (!UP_fgets(buf,size,bp->ptr)) + goto err; + } else - fgets(buf,size,(FILE *)bp->ptr); + { + if (!fgets(buf,size,(FILE *)bp->ptr)) + goto err; + } if (buf[0] != '\0') ret=strlen(buf); + err: return(ret); }