From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MMLmI-0001JR-Ke for qemu-devel@nongnu.org; Thu, 02 Jul 2009 08:52:38 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MMLmD-0001E5-8m for qemu-devel@nongnu.org; Thu, 02 Jul 2009 08:52:37 -0400 Received: from [199.232.76.173] (port=46873 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MMLmD-0001Di-2T for qemu-devel@nongnu.org; Thu, 02 Jul 2009 08:52:33 -0400 Received: from e39.co.us.ibm.com ([32.97.110.160]:58561) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MMLmC-0000gQ-KV for qemu-devel@nongnu.org; Thu, 02 Jul 2009 08:52:32 -0400 Received: from d03relay04.boulder.ibm.com (d03relay04.boulder.ibm.com [9.17.195.106]) by e39.co.us.ibm.com (8.13.1/8.13.1) with ESMTP id n62Cm92v023955 for ; Thu, 2 Jul 2009 06:48:09 -0600 Received: from d03av03.boulder.ibm.com (d03av03.boulder.ibm.com [9.17.195.169]) by d03relay04.boulder.ibm.com (8.13.8/8.13.8/NCO v9.2) with ESMTP id n62CqQTg163236 for ; Thu, 2 Jul 2009 06:52:27 -0600 Received: from d03av03.boulder.ibm.com (loopback [127.0.0.1]) by d03av03.boulder.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id n62CqQjZ006297 for ; Thu, 2 Jul 2009 06:52:26 -0600 Message-ID: <4A4CAD86.9020607@us.ibm.com> Date: Thu, 02 Jul 2009 07:52:22 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] rev3: support colon in filenames References: <1245862739.6278.7.camel@localhost> <1245866233.6278.17.camel@localhost> <4A434009.5010009@redhat.com> <1245998284.6278.99.camel@localhost> <4A447C8D.5000104@kevin-wolf.de> <1246063310.6278.115.camel@localhost> <1246511321.6429.31.camel@localhost> <4A4C754D.10109@redhat.com> In-Reply-To: <4A4C754D.10109@redhat.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: linuxram@us.ibm.com, qemu-devel@nongnu.org, kvm-devel Kevin Wolf wrote: > Ram Pai schrieb: > >> Problem: It is impossible to feed filenames with the character colon because >> qemu interprets such names as a protocol. For example filename scsi:0, is >> interpreted as a protocol by name "scsi". >> >> This patch allows user to escape colon characters. For example the above >> filename can now be expressed either as 'scsi\:0' or as file:scsi:0 >> >> anything following the "file:" tag is interpreted verbatim. However if "file:" >> tag is omitted then any colon characters in the string must be escaped using >> backslash. >> > > Anthony has already committed version 2 of the patch, so this one > doesn't apply any more. > > By the way, I'm still not convinced that this use of backslashes gives > us anything but yet another special character that worked just fine > before. I guess this is going to be annoying for Windows users. > It ends up working out for Windows users because colons are invalid in Windows file names. What's the solution to this problem is we don't escape? >> fat:c:\path\to\dir\:floppy\: is a fat file by name \path\to\dir:floppy: >> NOTE:The above example cannot be expressed using the "file:" protocol. >> > > And it doesn't need to. It's already expressed using the "fat:" > protocol, so we won't accidentally mistake c for the protocol name. > > You might have a point with a directory named :floppy: or so. > For 0.12, maybe we should take a hard look at refactoring -drive and completely splitting this stuff. I think we ought to come up with a syntax where we can pass file names as independent arguments so that no special escaping is required. Regards, Anthony Liguori