warning suppression
files.c: In function 'do_write_config_file':
files.c:2146:66: warning: format '%lu' expects argument of type 'long unsigned int', but argument 2 has type 'size_t' {aka 'unsigned int'} [-Wformat=]
2146 | pline("An error occurred, wrote only partial data (%lu/%lu).",
| ~~^
| |
| long unsigned int
| %u
2147 | wrote, len);
| ~~~~~
| |
| size_t {aka unsigned int}
files.c:2146:70: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t' {aka 'unsigned int'} [-Wformat=]
2146 | pline("An error occurred, wrote only partial data (%lu/%lu).",
| ~~^
| |
| long unsigned int
| %u
2147 | wrote, len);
| ~~~
| |
| size_t {aka unsigned int}
This commit is contained in:
@@ -2143,7 +2143,7 @@ do_write_config_file(void)
|
||||
fclose(fp);
|
||||
strbuf_empty(&buf);
|
||||
if (wrote != len)
|
||||
pline("An error occurred, wrote only partial data (%lu/%lu).",
|
||||
pline("An error occurred, wrote only partial data (%zu/%zu).",
|
||||
wrote, len);
|
||||
}
|
||||
return ECMD_OK;
|
||||
|
||||
Reference in New Issue
Block a user