[PATCH 2/2] Remove incorrect size specifier in spc_lu_init
Andy Grover <[email protected]> Tue, 18 Jul 2017 13:52:58 -0700
| Newsgroups | org.kernel.vger.stgt |
|---|---|
| Message-ID | <[email protected]> |
The vendor_id field is only 9 bytes, so GCC 7 complains when a size specifier of 16 is given. Signed-off-by: Andy Grover <[email protected]> --- usr/spc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr/spc.c b/usr/spc.c index cdb8a2a..82a6ec9 100644 --- a/usr/spc.c +++ b/usr/spc.c @@ -2069,7 +2069,7 @@ int spc_lu_init(struct scsi_lu *lu) lu->attrs.sense_format = 0; snprintf(lu->attrs.vendor_id, sizeof(lu->attrs.vendor_id), - "%-16s", VENDOR_ID); + "%-s", VENDOR_ID); snprintf(lu->attrs.product_rev, sizeof(lu->attrs.product_rev), "%s", "0001"); snprintf(lu->attrs.scsi_id, sizeof(lu->attrs.scsi_id), -- 2.9.4