Displaying 6 results from an estimated 6 matches for "mbr_id_str".
2017 Feb 14
2
[PATCH 1/2] GCC 7: Add __attribute__((noreturn)) to some usage functions which call exit.
This happens with GCC 7.0.1. The errors were all of the form:
qemu-speed-test.c: In function 'main':
qemu-speed-test.c:153:7: error: this statement may fall through [-Werror=implicit-fallthrough=]
usage (EXIT_SUCCESS);
^~~~~~~~~~~~~~~~~~~~
qemu-speed-test.c:155:5: note: here
default:
^~~~~~~
---
builder/index-validate.c | 2 +-
2015 Jul 02
0
[PATCH] Fix various -Wformat problems.
...a/cat/filesystems.c b/cat/filesystems.c
index 44defe0..0e64e00 100644
--- a/cat/filesystems.c
+++ b/cat/filesystems.c
@@ -868,7 +868,7 @@ write_row (const char *name, const char *type,
strings[len++] = vfs_label;
if ((columns & COLUMN_MBR)) {
if (mbr_id >= 0) {
- snprintf (mbr_id_str, sizeof mbr_id_str, "%02x", mbr_id);
+ snprintf (mbr_id_str, sizeof mbr_id_str, "%02x", (unsigned) mbr_id);
strings[len++] = mbr_id_str;
} else
strings[len++] = NULL;
diff --git a/cat/ls.c b/cat/ls.c
index 3bced54..987dcef 100644
--- a/cat/ls.c
+++ b/cat/...
2015 Jul 02
0
[PATCH v2] Fix various -Wformat problems.
...a/cat/filesystems.c b/cat/filesystems.c
index 44defe0..0e64e00 100644
--- a/cat/filesystems.c
+++ b/cat/filesystems.c
@@ -868,7 +868,7 @@ write_row (const char *name, const char *type,
strings[len++] = vfs_label;
if ((columns & COLUMN_MBR)) {
if (mbr_id >= 0) {
- snprintf (mbr_id_str, sizeof mbr_id_str, "%02x", mbr_id);
+ snprintf (mbr_id_str, sizeof mbr_id_str, "%02x", (unsigned) mbr_id);
strings[len++] = mbr_id_str;
} else
strings[len++] = NULL;
diff --git a/cat/ls.c b/cat/ls.c
index 3bced54..987dcef 100644
--- a/cat/ls.c
+++ b/cat/...
2017 Feb 14
0
[PATCH 2/2] GCC 7: Allocate sufficient space for sprintf output.
...(+), 18 deletions(-)
diff --git a/cat/filesystems.c b/cat/filesystems.c
index 1036c6f..4264b0f 100644
--- a/cat/filesystems.c
+++ b/cat/filesystems.c
@@ -866,7 +866,7 @@ write_row (const char *name, const char *type,
size_t len = 0;
char hum[LONGEST_HUMAN_READABLE];
char num[256];
- char mbr_id_str[3];
+ char mbr_id_str[9];
if ((columns & COLUMN_NAME))
strings[len++] = name;
diff --git a/daemon/9p.c b/daemon/9p.c
index a9e36d1..f72c8dd 100644
--- a/daemon/9p.c
+++ b/daemon/9p.c
@@ -71,9 +71,13 @@ do_list_9p (void)
if (d == NULL) break;
if (STRPREFIX (d->d_name, &...
2017 Feb 14
0
[PATCH v2 2/2] GCC 7: Allocate sufficient space for sprintf output.
...t;c-ctype.h"
#include "human.h"
+#include "intprops.h"
#include "getprogname.h"
#include "guestfs.h"
@@ -866,7 +867,7 @@ write_row (const char *name, const char *type,
size_t len = 0;
char hum[LONGEST_HUMAN_READABLE];
char num[256];
- char mbr_id_str[3];
+ char mbr_id_str[INT_BUFSIZE_BOUND (mbr_id)];
if ((columns & COLUMN_NAME))
strings[len++] = name;
diff --git a/daemon/9p.c b/daemon/9p.c
index a9e36d1..f72c8dd 100644
--- a/daemon/9p.c
+++ b/daemon/9p.c
@@ -71,9 +71,13 @@ do_list_9p (void)
if (d == NULL) break;
if (S...
2017 Feb 14
4
[PATCH v2 0/2] GCC 7: Misc fixes
v1 -> v2:
- Use intprops macro suggested by danpb.
Rich.