diff --git a/meson.build b/meson.build index 759e50fcc..2607c5c8f 100644 --- a/meson.build +++ b/meson.build @@ -81,7 +81,8 @@ common_flags = [ '-Wsign-compare', '-Wpointer-arith', '-Wpointer-sign', - '-Wformat', + '-Werror=format', + '-Wno-error=format-overflow', # avoid some "ā€˜%s’ directive argument is null" '-Wformat-security', '-Wimplicit-fallthrough', '-Wmissing-braces', diff --git a/spa/plugins/libcamera/libcamera-utils.cpp b/spa/plugins/libcamera/libcamera-utils.cpp index fdfd6e46d..7cbe565c6 100644 --- a/spa/plugins/libcamera/libcamera-utils.cpp +++ b/spa/plugins/libcamera/libcamera-utils.cpp @@ -807,7 +807,7 @@ mmap_init(struct impl *impl, struct port *port, port->memtype == SPA_DATA_MemFd) { d[j].flags |= SPA_DATA_FLAG_MAPPABLE; d[j].fd = bufs[i]->planes()[j].fd.get(); - spa_log_debug(impl->log, "Got fd = %ld for buffer: #%d", d[j].fd, i); + spa_log_debug(impl->log, "Got fd = %" PRId64 " for buffer: #%d", d[j].fd, i); d[j].data = NULL; SPA_FLAG_SET(b->flags, BUFFER_FLAG_ALLOCATED); } diff --git a/src/modules/module-pulse-tunnel.c b/src/modules/module-pulse-tunnel.c index 37b6f6d56..3e1592040 100644 --- a/src/modules/module-pulse-tunnel.c +++ b/src/modules/module-pulse-tunnel.c @@ -750,7 +750,7 @@ static void stream_latency_update_cb(pa_stream *s, void *userdata) pa_usec_t usec; int negative; pa_stream_get_latency(s, &usec, &negative); - pw_log_debug("latency %ld negative %d", usec, negative); + pw_log_debug("latency %" PRIu64 " negative %d", usec, negative); } static int create_pulse_stream(struct impl *impl)