From: Michal Privoznik Date: Thu, 6 Apr 2023 12:27:00 +0000 (+0200) Subject: viracpi: Fir error format string in virAcpiParseIORTNodeHeader() X-Git-Tag: v9.3.0-rc1~119 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ab6e04d7cef6d56a7fd7b617e281b245208b9f33;p=thirdparty%2Flibvirt.git viracpi: Fir error format string in virAcpiParseIORTNodeHeader() Inside of virAcpiParseIORTNodeHeader() there's an virReportError() which reports size of a structure using sizeof() operator. Well, it's not well documented but the returned type of sizeof() is apparently size_t but the format string uses %lu. Signed-off-by: Michal Privoznik --- diff --git a/src/util/viracpi.c b/src/util/viracpi.c index 74fff0f0ac..e66df99f03 100644 --- a/src/util/viracpi.c +++ b/src/util/viracpi.c @@ -102,7 +102,7 @@ virAcpiParseIORTNodeHeader(int fd, * least size of header itself. */ if (nodeHeader->len < sizeof(*nodeHeader)) { virReportError(VIR_ERR_INTERNAL_ERROR, - _("IORT table node type %1$s has invalid length: got %2$u, expected at least %3$lu"), + _("IORT table node type %1$s has invalid length: got %2$u, expected at least %3$zu"), NULLSTR(typeStr), (unsigned int)nodeHeader->len, sizeof(*nodeHeader)); return -1; }