Index: qemu/block.c
===================================================================
--- qemu.orig/block.c 2009-03-14 14:34:49.000000000 +0100
+++ qemu/block.c 2009-03-14 14:35:12.000000000 +0100
@@ -546,15 +546,7 @@ static int bdrv_check_byte_request(Block
static int bdrv_check_request(BlockDriverState *bs, int64_t sector_num,
int nb_sectors)
{
- int64_t offset;
-
- /* Deal with byte accesses */
- if (sector_num < 0)
- offset = -sector_num;
- else
- offset = sector_num * 512;
-
- return bdrv_check_byte_request(bs, offset, nb_sectors * 512);
+ return bdrv_check_byte_request(bs, sector_num * 512, nb_sectors * 512);
}
/* return < 0 if error. See bdrv_write() for the return codes */