nvme_manage: Rely on fgets to NULL terminate string

fgets guarantees that strings returned are NULL terminated,
so delete logic that attempts to insert a NULL terminator.

Change-Id: Ibeadcda9af431091b04daff41596d5738419b43f
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
This commit is contained in:
Ziye Yang 2017-03-24 09:17:59 +08:00 committed by Daniel Verkamp
parent ef91841763
commit fcc2eec870

View File

@ -786,7 +786,6 @@ update_firmware_image(void)
while (getchar() != '\n');
return;
}
path[strlen(path) - 1] = '\0';
fd = open(path, O_RDONLY);
if (fd < 0) {