aboutsummaryrefslogtreecommitdiff
path: root/cpus.c
diff options
context:
space:
mode:
Diffstat (limited to 'cpus.c')
-rw-r--r--cpus.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cpus.c b/cpus.c
index c232265cd2..c8bc8ad8b5 100644
--- a/cpus.c
+++ b/cpus.c
@@ -1278,7 +1278,7 @@ void qmp_memsave(int64_t addr, int64_t size, const char *filename,
f = fopen(filename, "wb");
if (!f) {
- error_set(errp, QERR_OPEN_FILE_FAILED, filename);
+ error_setg_file_open(errp, errno, filename);
return;
}
@@ -1308,7 +1308,7 @@ void qmp_pmemsave(int64_t addr, int64_t size, const char *filename,
f = fopen(filename, "wb");
if (!f) {
- error_set(errp, QERR_OPEN_FILE_FAILED, filename);
+ error_setg_file_open(errp, errno, filename);
return;
}