[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 2/3] block: bs->drv may be NULL in bdrv_debug_resume
From: |
Max Reitz |
Subject: |
[Qemu-devel] [PATCH 2/3] block: bs->drv may be NULL in bdrv_debug_resume() |
Date: |
Mon, 10 Mar 2014 23:44:08 +0100 |
Currently, bdrv_debug_resume() requires every bs->drv in the BDS stack
to be NULL until a bs->drv with an implementation of bdrv_debug_resume()
is found. For a normal function, this would be fine, but this is a
function for debugging purposes and should therefore allow intermediate
BDS not to have a driver (i.e., be "ejected"). Otherwise, it is hard to
debug such situations.
Signed-off-by: Max Reitz <address@hidden>
---
block.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/block.c b/block.c
index f1ef4b0..fb487f2 100644
--- a/block.c
+++ b/block.c
@@ -4055,7 +4055,7 @@ int bdrv_debug_remove_breakpoint(BlockDriverState *bs,
const char *tag)
int bdrv_debug_resume(BlockDriverState *bs, const char *tag)
{
- while (bs && bs->drv && !bs->drv->bdrv_debug_resume) {
+ while (bs && (!bs->drv || !bs->drv->bdrv_debug_resume)) {
bs = bs->file;
}
--
1.9.0
[Qemu-devel] [PATCH 2/3] block: bs->drv may be NULL in bdrv_debug_resume(),
Max Reitz <=
[Qemu-devel] [PATCH 3/3] iotests: Test corruption during COW request, Max Reitz, 2014/03/10
Re: [Qemu-devel] [PATCH 0/3] qcow2: Fix crash during copy_sectors() after corruption, Kevin Wolf, 2014/03/11
Re: [Qemu-devel] [PATCH 0/3] qcow2: Fix crash during copy_sectors() after corruption, Stefan Hajnoczi, 2014/03/11