提交 eab2ac9d 编写于 作者: P Paolo Bonzini 提交者: Michael Tokarev

block/ssh: remove dead code

The "err" label cannot be reached with qp != NULL.  Remove the free-ing
of qp and avoid future regressions by removing the initializer.
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
ACKed-by: NRichard W.M. Jones <rjones@redhat.com>
Reviewed-by: NFam Zheng <famz@redhat.com>
Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
上级 dc144220
......@@ -193,7 +193,7 @@ sftp_error_report(BDRVSSHState *s, const char *fs, ...)
static int parse_uri(const char *filename, QDict *options, Error **errp)
{
URI *uri = NULL;
QueryParams *qp = NULL;
QueryParams *qp;
int i;
uri = uri_parse(filename);
......@@ -249,9 +249,6 @@ static int parse_uri(const char *filename, QDict *options, Error **errp)
return 0;
err:
if (qp) {
query_params_free(qp);
}
if (uri) {
uri_free(uri);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册