From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52471) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLuuA-0003lR-Um for qemu-devel@nongnu.org; Fri, 07 Mar 2014 08:33:44 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WLuu5-0001mZ-VQ for qemu-devel@nongnu.org; Fri, 07 Mar 2014 08:33:38 -0500 Received: from mx1.redhat.com ([209.132.183.28]:55483) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLuu5-0001mU-OI for qemu-devel@nongnu.org; Fri, 07 Mar 2014 08:33:33 -0500 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s27DXXdl006900 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 7 Mar 2014 08:33:33 -0500 From: Kevin Wolf Date: Fri, 7 Mar 2014 14:33:01 +0100 Message-Id: <1394199187-9576-14-git-send-email-kwolf@redhat.com> In-Reply-To: <1394199187-9576-1-git-send-email-kwolf@redhat.com> References: <1394199187-9576-1-git-send-email-kwolf@redhat.com> Subject: [Qemu-devel] [PULL 13/19] block/raw-win32: Strip "file:" prefix on creation List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: kwolf@redhat.com From: Max Reitz The bdrv_create() implementation of the block/raw-win32 "file" protocol driver should strip the "file:" prefix from filenames if present. Signed-off-by: Max Reitz Reviewed-by: Eric Blake Reviewed-by: Benoit Canet Signed-off-by: Kevin Wolf --- block/raw-win32.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/block/raw-win32.c b/block/raw-win32.c index 0755434..9954748 100644 --- a/block/raw-win32.c +++ b/block/raw-win32.c @@ -481,6 +481,8 @@ static int raw_create(const char *filename, QEMUOptionParameter *options, int fd; int64_t total_size = 0; + strstart(filename, "file:", &filename); + /* Read out options */ while (options && options->name) { if (!strcmp(options->name, BLOCK_OPT_SIZE)) { -- 1.8.1.4