提交 0206984a 编写于 作者: J Jim Fehlig 提交者: Cole Robinson

libxl: don't overwrite error from virNetSocketNewConnectTCP()

Remove redundant error reporting in libxlDomainMigrationPerform().
virNetSocketNewConnectTCP() is perfectly capable of reporting
sensible errors.

(cherry picked from commit 6ce939c2)
上级 999a873d
......@@ -472,7 +472,6 @@ libxlDomainMigrationPerform(libxlDriverPrivatePtr driver,
virURIPtr uri = NULL;
virNetSocketPtr sock;
int sockfd = -1;
int saved_errno = EINVAL;
int ret = -1;
/* parse dst host:port from uri */
......@@ -487,12 +486,8 @@ libxlDomainMigrationPerform(libxlDriverPrivatePtr driver,
/* socket connect to dst host:port */
if (virNetSocketNewConnectTCP(hostname, portstr,
AF_UNSPEC,
&sock) < 0) {
virReportSystemError(saved_errno,
_("unable to connect to '%s:%s'"),
hostname, portstr);
&sock) < 0)
goto cleanup;
}
if (virNetSocketSetBlocking(sock, true) < 0) {
virObjectUnref(sock);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册