Message ID | 1454161873-16279-1-git-send-email-colin.king@canonical.com |
---|---|
State | Accepted |
Headers | show |
On 2016年01月30日 21:51, Colin King wrote: > From: Colin Ian King <colin.king@canonical.com> > > 32 bit builds are failing with: > > In file included from ../src/lib/include/fwts_binpaths.h:27:0, > from ../src/lib/include/fwts.h:40, > from acpi/madt/madt.c:16: > acpi/madt/madt.c: In function 'madt_local_sapic': > acpi/madt/madt.c:644:8: error: format '%ld' expects argument of type 'long int', > but argument 9 has type 'size_t {aka unsigned int}' [-Werror=format=] > "MADT %s length of %d bytes does not match " > ^ > ../src/lib/include/fwts_framework.h:229:76: note: in definition of macro 'fwts_failed' > fwts_framework_log(fw, LOG_FAILED, label, level, &fw->minor_tests.failed, fmt, ## args) > > use the %zd format specifier for size_t types > > Signed-off-by: Colin Ian King <colin.king@canonical.com> > --- > src/acpi/madt/madt.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/acpi/madt/madt.c b/src/acpi/madt/madt.c > index 2c06d2c..15bfe10 100644 > --- a/src/acpi/madt/madt.c > +++ b/src/acpi/madt/madt.c > @@ -642,7 +642,7 @@ static int madt_local_sapic(fwts_framework *fw, > fwts_failed(fw, LOG_LEVEL_MEDIUM, > "MADTLSAPICLength", > "MADT %s length of %d bytes does not match " > - "actual length of %ld bytes.", > + "actual length of %zd bytes.", > madt_sub_names[hdr->type], hdr->length, > strlen(lsapic->uid_string) + 16); > else > Acked-by: Ivan Hu <ivan.hu@canonical.com>
On 2016-01-30 09:51 PM, Colin King wrote: > From: Colin Ian King <colin.king@canonical.com> > > 32 bit builds are failing with: > > In file included from ../src/lib/include/fwts_binpaths.h:27:0, > from ../src/lib/include/fwts.h:40, > from acpi/madt/madt.c:16: > acpi/madt/madt.c: In function 'madt_local_sapic': > acpi/madt/madt.c:644:8: error: format '%ld' expects argument of type 'long int', > but argument 9 has type 'size_t {aka unsigned int}' [-Werror=format=] > "MADT %s length of %d bytes does not match " > ^ > ../src/lib/include/fwts_framework.h:229:76: note: in definition of macro 'fwts_failed' > fwts_framework_log(fw, LOG_FAILED, label, level, &fw->minor_tests.failed, fmt, ## args) > > use the %zd format specifier for size_t types > > Signed-off-by: Colin Ian King <colin.king@canonical.com> > --- > src/acpi/madt/madt.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/acpi/madt/madt.c b/src/acpi/madt/madt.c > index 2c06d2c..15bfe10 100644 > --- a/src/acpi/madt/madt.c > +++ b/src/acpi/madt/madt.c > @@ -642,7 +642,7 @@ static int madt_local_sapic(fwts_framework *fw, > fwts_failed(fw, LOG_LEVEL_MEDIUM, > "MADTLSAPICLength", > "MADT %s length of %d bytes does not match " > - "actual length of %ld bytes.", > + "actual length of %zd bytes.", > madt_sub_names[hdr->type], hdr->length, > strlen(lsapic->uid_string) + 16); > else > Acked-by: Alex Hung <alex.hung@canonical.com>
diff --git a/src/acpi/madt/madt.c b/src/acpi/madt/madt.c index 2c06d2c..15bfe10 100644 --- a/src/acpi/madt/madt.c +++ b/src/acpi/madt/madt.c @@ -642,7 +642,7 @@ static int madt_local_sapic(fwts_framework *fw, fwts_failed(fw, LOG_LEVEL_MEDIUM, "MADTLSAPICLength", "MADT %s length of %d bytes does not match " - "actual length of %ld bytes.", + "actual length of %zd bytes.", madt_sub_names[hdr->type], hdr->length, strlen(lsapic->uid_string) + 16); else