mirror of
https://gitlab.freedesktop.org/xorg/lib/libx11.git
synced 2026-05-09 02:38:12 +02:00
RETURN: add do ... while (0) to avoid -Wextra-semi-stmt warnings
Clears 5 warnings from clang of the form:
RdBitF.c:141:32: warning: empty expression statement has no effect;
remove unnecessary ';' to silence this warning [-Wextra-semi-stmt]
RETURN (BitmapFileInvalid);
^
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Part-of: <https://gitlab.freedesktop.org/xorg/lib/libx11/-/merge_requests/272>
This commit is contained in:
parent
38c642c8eb
commit
6891228821
1 changed files with 1 additions and 1 deletions
|
|
@ -134,7 +134,7 @@ XReadBitmapFileData (
|
|||
|
||||
/* error cleanup and return macro */
|
||||
#define RETURN(code) \
|
||||
{ Xfree (bits); fclose (fstream); return code; }
|
||||
do { Xfree (bits); fclose (fstream); return code; } while (0)
|
||||
|
||||
while (fgets(line, MAX_SIZE, fstream)) {
|
||||
if (strlen(line) == MAX_SIZE-1)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue