提交 4fd5c2fb 编写于 作者: J Julio Faracco 提交者: Peter Krempa

util: remove dead code inside virstoragefile

The host address or the socket path have already been checked at the
begining of the function virStorageSourceParseNBDColonString(). So,
when the parameter is not a unix socket, there is no reason to check
the address again because if it does not exists, the logic will fail
in the first IF conditional.
Signed-off-by: NJulio Faracco <jcfaracco@gmail.com>
上级 54aee01d
......@@ -2635,13 +2635,6 @@ virStorageSourceParseNBDColonString(const char *nbdstr,
goto cleanup;
} else {
if (!backing[1]) {
virReportError(VIR_ERR_INTERNAL_ERROR,
_("missing host name in nbd string '%s'"),
nbdstr);
goto cleanup;
}
if (VIR_STRDUP(src->hosts->name, backing[1]) < 0)
goto cleanup;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册