Bugzilla – Attachment 772119 Details for
Bug 1092543
GCC 8: xen build fails
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Forgot Password
[patch]
patch candidate
0001-Fix-GCC-8-warning-on-i586.patch (text/plain), 1.78 KB, created by
Martin Liška
on 2018-06-01 12:04:37 UTC
(
hide
)
Description:
patch candidate
Filename:
MIME Type:
Creator:
Martin Liška
Created:
2018-06-01 12:04:37 UTC
Size:
1.78 KB
patch
obsolete
>From bc2c1eab55a34acc054ec6dbeb0184a599323478 Mon Sep 17 00:00:00 2001 >From: marxin <mliska@suse.cz> >Date: Fri, 1 Jun 2018 13:29:59 +0200 >Subject: [PATCH] Fix GCC 8 warning on i586: > >xenpmd.c: In function 'write_battery_info_to_xenstore': >xenpmd.c:354:23: error: '%02x' directive output may be truncated writing between 2 and 8 bytes into a region of size 3 [-Werror=format-truncation=] > snprintf(val, 3, "%02x", > ^~~~ >xenpmd.c:354:22: note: directive argument in the range [40, 2147483778] > snprintf(val, 3, "%02x", > ^~~~~~ >In file included from /usr/include/stdio.h:862, > from xenpmd.c:35: >/usr/include/bits/stdio2.h:64:10: note: '__builtin___snprintf_chk' output between 3 and 9 bytes into a destination of size 3 > return __builtin___snprintf_chk (__s, __n, __USE_FORTIFY_LEVEL - 1, > ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > __bos (__s), __fmt, __va_arg_pack ()); > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >--- > tools/xenpmd/xenpmd.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/tools/xenpmd/xenpmd.c b/tools/xenpmd/xenpmd.c >index 56412a9a81..e49de1aee6 100644 >--- a/tools/xenpmd/xenpmd.c >+++ b/tools/xenpmd/xenpmd.c >@@ -356,7 +356,7 @@ void write_battery_info_to_xenstore(struct battery_info *info) > strlen(info->model_number) + > strlen(info->serial_number) + > strlen(info->battery_type) + >- strlen(info->oem_info) + 4)); >+ strlen(info->oem_info) + 4) & 0xff); > write_ulong_lsb_first(val+2, info->present); > write_ulong_lsb_first(val+10, info->design_capacity); > write_ulong_lsb_first(val+18, info->last_full_capacity); >-- >2.17.0 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 1092543
: 772119