mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-26 10:03:40 +03:00
scsi_id: remove trailing garbage from ID_SERIAL_SHORT
This commit is contained in:
parent
64e6d9dd70
commit
5284454d5f
@ -732,6 +732,7 @@ static int do_scsi_page80_inquiry(struct sysfs_device *dev_scsi, int fd,
|
||||
for (i = 4; i < len + 4; i++, ser_ind++)
|
||||
serial[ser_ind] = buf[i];
|
||||
memcpy(serial_short, &buf[4], len);
|
||||
serial_short[len] = '\0';
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user