From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1L7bRr-000345-GK for qemu-devel@nongnu.org; Tue, 02 Dec 2008 15:02:19 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1L7bRq-00033t-21 for qemu-devel@nongnu.org; Tue, 02 Dec 2008 15:02:18 -0500 Received: from [199.232.76.173] (port=39968 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L7bRp-00033q-Sr for qemu-devel@nongnu.org; Tue, 02 Dec 2008 15:02:17 -0500 Received: from savannah.gnu.org ([199.232.41.3]:36399 helo=sv.gnu.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1L7bRo-0003P7-Lb for qemu-devel@nongnu.org; Tue, 02 Dec 2008 15:02:17 -0500 Received: from cvs.savannah.gnu.org ([199.232.41.69]) by sv.gnu.org with esmtp (Exim 4.63) (envelope-from ) id 1L7bRn-0008Hu-SO for qemu-devel@nongnu.org; Tue, 02 Dec 2008 20:02:15 +0000 Received: from aliguori by cvs.savannah.gnu.org with local (Exim 4.63) (envelope-from ) id 1L7bRn-0008Hf-D1 for qemu-devel@nongnu.org; Tue, 02 Dec 2008 20:02:15 +0000 MIME-Version: 1.0 Errors-To: aliguori Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Anthony Liguori Message-Id: Date: Tue, 02 Dec 2008 20:02:15 +0000 Subject: [Qemu-devel] [5856] Exclude unix: from vnc call to unix_listen() (Ryan Harper) Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org 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 Signed-off-by: Anthony Liguori 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); }