On 2014-12-01 at 17:01, Eric Blake wrote:
On 11/27/2014 07:48 AM, Max Reitz wrote:
We can always assume raw, file and qcow2 being available; so do not use
bdrv_find_format() to locate their BlockDriver objects but statically
reference the respective objects.
Cc: qemu-sta...@nongnu.org
Signed-off-by: Max Reitz <mre...@redhat.com>
---
block.c | 11 ++---------
1 file changed, 2 insertions(+), 9 deletions(-)
Reviewed-by: Eric Blake <ebl...@redhat.com>
@@ -1293,7 +1288,6 @@ int bdrv_append_temp_snapshot(BlockDriverState *bs, int
flags, Error **errp)
/* TODO: extra byte is a hack to ensure MAX_PATH space on Windows. */
char *tmp_filename = g_malloc0(PATH_MAX + 1);
int64_t total_size;
- BlockDriver *bdrv_qcow2;
Hmm - how hard would it be to get qemu to be clean under -Wshadow? This
is a case where you would have had to change this hunk during patch 1 if
-Wshadow were in effect.
Well, I know I once found a bug which would have been spotted by
-Wshadow; so in principle, I'm in favor of trying to enforce -Wshadow.
On the other hand, I guess it may be really hard. We could try some
time, but I don't want to have to run through all of qemu's code...
Max