aboutsummaryrefslogtreecommitdiff
path: root/dump/dump.c
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2020-07-07 18:06:04 +0200
committerMarkus Armbruster <armbru@redhat.com>2020-07-10 15:18:08 +0200
commit992861fb1e4cf410f30ec8f05bd2dc2a14a5a027 (patch)
tree9d4d5de47d4ebae50838cd7f8ea39b89a3604507 /dump/dump.c
parentaf175e85f92c870386ad74f466e29537b79611d3 (diff)
downloadqemu-992861fb1e4cf410f30ec8f05bd2dc2a14a5a027.zip
qemu-992861fb1e4cf410f30ec8f05bd2dc2a14a5a027.tar.gz
qemu-992861fb1e4cf410f30ec8f05bd2dc2a14a5a027.tar.bz2
error: Eliminate error_propagate() manually
When all we do with an Error we receive into a local variable is propagating to somewhere else, we can just as well receive it there right away. The previous two commits did that for sufficiently simple cases with Coccinelle. Do it for several more manually. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Message-Id: <20200707160613.848843-37-armbru@redhat.com>
Diffstat (limited to 'dump/dump.c')
-rw-r--r--dump/dump.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/dump/dump.c b/dump/dump.c
index 248ea06..383bc78 100644
--- a/dump/dump.c
+++ b/dump/dump.c
@@ -1031,14 +1031,11 @@ out:
static void write_dump_header(DumpState *s, Error **errp)
{
- Error *local_err = NULL;
-
if (s->dump_info.d_class == ELFCLASS32) {
- create_header32(s, &local_err);
+ create_header32(s, errp);
} else {
- create_header64(s, &local_err);
+ create_header64(s, errp);
}
- error_propagate(errp, local_err);
}
static size_t dump_bitmap_get_bufsize(DumpState *s)