rom loader: use qemu_strdup.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
9c282718aa
commit
14a3f32d9e
@ -559,7 +559,7 @@ int rom_add_file(const char *file,
|
||||
rom->name = qemu_strdup(file);
|
||||
rom->path = qemu_find_file(QEMU_FILE_TYPE_BIOS, rom->name);
|
||||
if (rom->path == NULL) {
|
||||
rom->path = strdup(file);
|
||||
rom->path = qemu_strdup(file);
|
||||
}
|
||||
|
||||
fd = open(rom->path, O_RDONLY | O_BINARY);
|
||||
|
Loading…
x
Reference in New Issue
Block a user