Tidy inflateEnd calls

So that no one need worry about the value of Z_OK.

bfd/
	* compress.c (decompress_contents): Tidy inflateEnd result test.
binutils/
	* readelf.c (uncompress_section_contents): Tidy inflateEnd result test.
This commit is contained in:
Alan Modra 2021-01-16 09:45:09 +10:30
parent eb6e6af8c1
commit ad92f33d38
4 changed files with 11 additions and 4 deletions

View file

@ -14229,8 +14229,8 @@ uncompress_section_contents (unsigned char ** buffer,
break;
rc = inflateReset (& strm);
}
rc |= inflateEnd (& strm);
if (rc != Z_OK
if (inflateEnd (& strm) != Z_OK
|| rc != Z_OK
|| strm.avail_out != 0)
goto fail;