mirror of
https://github.com/libvirt/libvirt.git
synced 2026-10-02 12:20:06 -05:00
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 6ce939c247)
This commit is contained in:
1 parent
999a873db0
commit
0206984abb
1 file changed
+1
-6
@@ -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);
|
||||
|
||||
Reference in new issue
Block a user