Skip to content

Commit

Permalink
Silence format-zero-length warning
Browse files Browse the repository at this point in the history
  • Loading branch information
saghul committed Sep 5, 2024
1 parent 048f427 commit 7788436
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions quickjs.c
Original file line number Diff line number Diff line change
Expand Up @@ -34043,6 +34043,7 @@ typedef struct BCReaderState {
} BCReaderState;

#ifdef DUMP_READ_OBJECT
#pragma GCC diagnostic ignored "-Wformat-zero-length"
static void __attribute__((format(printf, 2, 3))) bc_read_trace(BCReaderState *s, const char *fmt, ...) {
va_list ap;
int i, n, n0;
Expand Down Expand Up @@ -34076,6 +34077,7 @@ static void __attribute__((format(printf, 2, 3))) bc_read_trace(BCReaderState *s
if (strchr(fmt, '{'))
s->level++;
}
#pragma GCC diagnostic warning "-Wformat-zero-length"
#else
#define bc_read_trace(...)
#endif
Expand Down

0 comments on commit 7788436

Please sign in to comment.