From 51de97605b183fe5a84f96f411cfc99ba6bbb6b1 Mon Sep 17 00:00:00 2001 From: aliguori Date: Thu, 5 Mar 2009 23:00:43 +0000 Subject: block: Improve bdrv_iterate (Jan Kiszka) Make bdrv_iterate more useful by passing the BlockDriverState to the iterator instead of the device name. Signed-off-by: Jan Kiszka Signed-off-by: Anthony Liguori git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6703 c046a42c-6fe2-441c-8c8c-71466251a162 --- monitor.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'monitor.c') diff --git a/monitor.c b/monitor.c index 513eca9..2d1b86e 100644 --- a/monitor.c +++ b/monitor.c @@ -2679,8 +2679,9 @@ static void file_completion(const char *input) closedir(ffs); } -static void block_completion_it(void *opaque, const char *name) +static void block_completion_it(void *opaque, BlockDriverState *bs) { + const char *name = bdrv_get_device_name(bs); const char *input = opaque; if (input[0] == '\0' || -- cgit v1.1