diff options
author | Philippe Mathieu-Daudé <f4bug@amsat.org> | 2018-06-29 15:11:00 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2018-06-29 15:11:00 +0100 |
commit | 88bbd3fb60bf16ed3e974276814df4e9c4b2b92f (patch) | |
tree | 29180de2eeb8382c724be65bc8fba51bf009e692 /device_tree.c | |
parent | 329b72916f54a6ef2842ae172c086986af19c677 (diff) |
hw/arm/sysbus-fdt: Replace error_setg(&error_fatal) by error_report() + exit()
Use error_report() + exit() instead of error_setg(&error_fatal),
as suggested by the "qapi/error.h" documentation:
Please don't error_setg(&error_fatal, ...), use error_report() and
exit(), because that's more obvious.
This fixes CID 1352173:
"Passing null pointer dt_name to qemu_fdt_node_path, which dereferences it."
And this also fixes:
hw/arm/sysbus-fdt.c:322:9: warning: Array access (from variable 'node_path') results in a null pointer dereference
if (node_path[1]) {
^~~~~~~~~~~~
Fixes: Coverity CID 1352173 (Dereference after null check)
Suggested-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Eric Auger <eric.auger@redhat.com>
Message-id: 20180625165749.3910-3-f4bug@amsat.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'device_tree.c')
0 files changed, 0 insertions, 0 deletions