mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 10:12:06 +00:00
Check RGBGFX warning/error format strings with format_ macro
This commit is contained in:
@@ -260,7 +260,7 @@ static void generate_random_image(char const *filename) {
|
||||
write_image(filename, palettes, tileData, attributes, width, height);
|
||||
}
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
int main(int argc, char *argv[]) {
|
||||
if (argc < 3 || argc > 4) {
|
||||
fprintf(stderr, "usage: %s <input file> <basename> [<maxcount>]\n", argv[0]);
|
||||
return 2;
|
||||
|
||||
@@ -112,9 +112,9 @@ class Png {
|
||||
|
||||
if (nbBytesRead != expectedLen) {
|
||||
fatal("Error reading input image (\"%s\"): file too short (expected at least %zd more "
|
||||
"bytes after reading %lld)",
|
||||
"bytes after reading %zu)",
|
||||
self->path.c_str(), length - nbBytesRead,
|
||||
self->file.pubseekoff(0, std::ios_base::cur));
|
||||
(size_t)self->file.pubseekoff(0, std::ios_base::cur));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -369,7 +369,7 @@ static char *execProg(char const *name, char * const *argv) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
int main(int argc, char *argv[]) {
|
||||
if (argc < 2) {
|
||||
fprintf(stderr, "usage: %s <rng file> [rgbgfx flags]\n", argv[0]);
|
||||
exit(0);
|
||||
|
||||
Reference in New Issue
Block a user