summaryrefslogtreecommitdiffstats
path: root/src/guestfs.c
diff options
context:
space:
mode:
authorRichard Jones <rjones@redhat.com>2010-04-08 18:53:40 +0100
committerRichard Jones <rjones@redhat.com>2010-04-08 18:53:40 +0100
commitfb4ec82d97f71963ea7f830cb0bc38abefcbac99 (patch)
tree57c590e5375f93794c61ff23894cc6262910ee33 /src/guestfs.c
parent50195d6ec4e893f894ef1bbf7af6eeda56f96600 (diff)
downloadlibguestfs-fb4ec82d97f71963ea7f830cb0bc38abefcbac99.tar.gz
libguestfs-fb4ec82d97f71963ea7f830cb0bc38abefcbac99.tar.xz
libguestfs-fb4ec82d97f71963ea7f830cb0bc38abefcbac99.zip
Fix for "warning: unexpected connection from UID ..."
This warning is currently a fatal error. The code attempts to retry the accept call, but because we don't reset sock = -1 the retry doesn't happen and it dies anyway. Set sock = -1 so the retry attempt can happen.
Diffstat (limited to 'src/guestfs.c')
-rw-r--r--src/guestfs.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/guestfs.c b/src/guestfs.c
index e235fdcd..ed514dce 100644
--- a/src/guestfs.c
+++ b/src/guestfs.c
@@ -1405,6 +1405,7 @@ guestfs__launch (guestfs_h *g)
"libguestfs: warning: unexpected connection from UID %d to port %d\n",
uid, null_vmchannel_sock);
close (sock);
+ sock = -1;
continue;
}
}