qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Anthony Liguori <anthony@codemonkey.ws>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [5856] Exclude unix: from vnc call to unix_listen() (Ryan Harper)
Date: Tue, 02 Dec 2008 20:02:15 +0000	[thread overview]
Message-ID: <E1L7bRn-0008Hf-D1@cvs.savannah.gnu.org> (raw)

Revision: 5856
          http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=5856
Author:   aliguori
Date:     2008-12-02 20:02:14 +0000 (Tue, 02 Dec 2008)

Log Message:
-----------
Exclude unix: from vnc call to unix_listen() (Ryan Harper)

When using an existing unix socket like:

 -vnc unix:/tmp/file1Y2nY2

qemu fails to bind a unix socket because the vnc call to unix_listen includes
the unix: prefix and stores that in the unix.sun_path.  The fix is to not pass
in unix: for the filename (same way qemu-char.c does it).

Signed-off-by: Ryan Harper <ryanh@us.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>

Modified Paths:
--------------
    trunk/vnc.c

Modified: trunk/vnc.c
===================================================================
--- trunk/vnc.c	2008-12-02 19:40:26 UTC (rev 5855)
+++ trunk/vnc.c	2008-12-02 20:02:14 UTC (rev 5856)
@@ -2544,7 +2544,7 @@
         dpy = qemu_malloc(256);
         if (strncmp(display, "unix:", 5) == 0) {
             strcpy(dpy, "unix:");
-            vs->lsock = unix_listen(display, dpy+5, 256-5);
+            vs->lsock = unix_listen(display+5, dpy+5, 256-5);
         } else {
             vs->lsock = inet_listen(display, dpy, 256, SOCK_STREAM, 5900);
         }

                 reply	other threads:[~2008-12-02 20:02 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E1L7bRn-0008Hf-D1@cvs.savannah.gnu.org \
    --to=anthony@codemonkey.ws \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).