From: Alain Spineux Date: Tue, 6 Jun 2023 12:58:52 +0000 (+0200) Subject: tweak fix warning X-Git-Tag: Beta-15.0.0~176 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6d1a588a968d4f70d0233e7ef2a07144be0fe3b3;p=thirdparty%2Fbacula.git tweak fix warning ../plugins/fd/fd_common.h:528:32: warning: format ‘%lld’ expects argument of type ‘long long int’, but argument 3 has type ‘int64_t’ {aka ‘long int’} [-Wformat=] 528 | l = fprintf(fp, "time=%lld level=%c key=%s name=%s vollen=%d vol=%s\n", ../plugins/fd/fd_common.h:528:66: warning: format ‘%d’ expects argument of type ‘int’, but argument 7 has type ‘size_t’ {aka ‘long unsigned int’} [-Wformat=] 528 | l = fprintf(fp, "time=%lld level=%c key=%s name=%s vollen=%d vol=%s\n", --- diff --git a/bacula/src/plugins/fd/fd_common.h b/bacula/src/plugins/fd/fd_common.h index 7957ad3fb..da85457df 100644 --- a/bacula/src/plugins/fd/fd_common.h +++ b/bacula/src/plugins/fd/fd_common.h @@ -528,11 +528,11 @@ bool joblist::store_job(char *data) if (level == 'F') { l = fprintf(fp, "time=%lld level=%c key=%s name=%s vollen=%d vol=%s\n", - now, level, key, name, strlen(data), data); + (long long)now, level, key, name, (int)strlen(data), data); } else { l = fprintf(fp, "time=%lld level=%c key=%s name=%s root=%s prev=%s vollen=%d vol=%s\n", - now, level, key, name, root, prev, strlen(data), data); + (long long)now, level, key, name, root, prev, (int)strlen(data), data); } unbash_spaces(data);