mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-23 14:15:28 +00:00
remoteDomainGetFSInfo: remove unreachable cleanup code
Signed-off-by: Pavel Hrdina <phrdina@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
5ca76b9fbf
commit
caaf792eed
@ -7633,7 +7633,6 @@ remoteDomainGetFSInfo(virDomainPtr dom,
|
||||
remote_domain_get_fsinfo_args args;
|
||||
remote_domain_get_fsinfo_ret ret;
|
||||
remote_domain_fsinfo *src;
|
||||
virDomainFSInfoPtr *info_ret = NULL;
|
||||
|
||||
remoteDriverLock(priv);
|
||||
|
||||
@ -7656,6 +7655,8 @@ remoteDomainGetFSInfo(virDomainPtr dom,
|
||||
}
|
||||
|
||||
if (info) {
|
||||
virDomainFSInfoPtr *info_ret = NULL;
|
||||
|
||||
if (!ret.info.info_len) {
|
||||
*info = NULL;
|
||||
rv = ret.ret;
|
||||
@ -7685,17 +7686,11 @@ remoteDomainGetFSInfo(virDomainPtr dom,
|
||||
}
|
||||
|
||||
*info = info_ret;
|
||||
info_ret = NULL;
|
||||
}
|
||||
|
||||
rv = ret.ret;
|
||||
|
||||
cleanup:
|
||||
if (info_ret) {
|
||||
for (i = 0; i < ret.info.info_len; i++)
|
||||
virDomainFSInfoFree(info_ret[i]);
|
||||
VIR_FREE(info_ret);
|
||||
}
|
||||
xdr_free((xdrproc_t)xdr_remote_domain_get_fsinfo_ret,
|
||||
(char *) &ret);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user