aboutsummaryrefslogtreecommitdiff
path: root/bsd-user/openbsd
diff options
context:
space:
mode:
authorDongli Zhang <dongli.zhang@oracle.com>2023-12-13 16:31:17 -0800
committerMichael S. Tsirkin <mst@redhat.com>2023-12-26 04:51:02 -0500
commit551bf7b4c1795ef89407039dd908c2f199b122c2 (patch)
tree48b643fd5e3d096560a50494788510c2edbb2ee2 /bsd-user/openbsd
parent45e48809d3d0328fd2f113b878a62a27f1360664 (diff)
downloadqemu-551bf7b4c1795ef89407039dd908c2f199b122c2.zip
qemu-551bf7b4c1795ef89407039dd908c2f199b122c2.tar.gz
qemu-551bf7b4c1795ef89407039dd908c2f199b122c2.tar.bz2
vhost-scsi: fix usage of error_reportf_err()
It is required to use error_report() instead of error_reportf_err(), if the prior function does not take local_err as the argument. As a result, the local_err is always NULL and segment fault may happen. vhost_scsi_start() -> vhost_scsi_set_endpoint(s) --> does not allocate local_err -> error_reportf_err() -> error_vprepend() -> g_string_append(newmsg, (*errp)->msg) --> (*errp) is NULL In addition, add ": " at the end of other error_reportf_err() logs. Fixes: 7962e432b4e4 ("vhost-user-scsi: support reconnect to backend") Signed-off-by: Dongli Zhang <dongli.zhang@oracle.com> Message-Id: <20231214003117.43960-1-dongli.zhang@oracle.com> Reviewed-by: Feng Li <fengli@smartx.com> Reviewed-by: Raphael Norwitz <raphael.norwitz@nutanix.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'bsd-user/openbsd')
0 files changed, 0 insertions, 0 deletions