mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
QemuOpts: Fix qemu_config_parse() to catch file read errors
This commit is contained in:
@@ -475,6 +475,10 @@ int qemu_config_parse(FILE *fp, const char *fname)
|
||||
error_report("parse error");
|
||||
goto out;
|
||||
}
|
||||
if (ferror(fp)) {
|
||||
error_report("error reading file");
|
||||
goto out;
|
||||
}
|
||||
res = 0;
|
||||
out:
|
||||
loc_pop(&loc);
|
||||
|
||||
Reference in New Issue
Block a user