[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH for-3.1 v10 04/31] block: Add BDS.auto_backing_f
From: |
Alberto Garcia |
Subject: |
Re: [Qemu-devel] [PATCH for-3.1 v10 04/31] block: Add BDS.auto_backing_file |
Date: |
Tue, 11 Sep 2018 10:45:45 +0200 |
User-agent: |
Notmuch/0.18.2 (http://notmuchmail.org) Emacs/24.4.1 (i586-pc-linux-gnu) |
On Thu 09 Aug 2018 11:35:01 PM CEST, Max Reitz wrote:
> @@ -295,11 +296,13 @@ static int qcow_open(BlockDriverState *bs, QDict
> *options, int flags,
> goto fail;
> }
> ret = bdrv_pread(bs->file, header.backing_file_offset,
> - bs->backing_file, len);
> + bs->auto_backing_file, len);
> if (ret < 0) {
> goto fail;
> }
> - bs->backing_file[len] = '\0';
> + bs->auto_backing_file[len] = '\0';
> + pstrcpy(bs->backing_file, sizeof(bs->backing_file),
> + bs->auto_backing_file);
> }
The patch looks fine, I just wonder why you don't simply copy
bs->backing_file into bs->auto_backing_file instead of the other way
around, it would make the patch smaller.
Either way,
Reviewed-by: Alberto Garcia <address@hidden>
Berto
- Re: [Qemu-devel] [PATCH for-3.1 v10 04/31] block: Add BDS.auto_backing_file,
Alberto Garcia <=