[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 03/21] qemu-io: Fix if scoping bug
From: |
Kevin Wolf |
Subject: |
[Qemu-devel] [PATCH 03/21] qemu-io: Fix if scoping bug |
Date: |
Tue, 19 Jul 2011 12:15:06 +0200 |
From: Devin Nakamura <address@hidden>
Fix a bug caused by lack of braces in if statement
Lack of braces means that if(count & 0x1ff) is never reached
Signed-off-by: Devin Nakamura <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>
---
qemu-io.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/qemu-io.c b/qemu-io.c
index e3c825f..a553d0c 100644
--- a/qemu-io.c
+++ b/qemu-io.c
@@ -449,7 +449,7 @@ static int read_f(int argc, char **argv)
return 0;
}
- if (!pflag)
+ if (!pflag) {
if (offset & 0x1ff) {
printf("offset %" PRId64 " is not sector aligned\n",
offset);
@@ -460,6 +460,7 @@ static int read_f(int argc, char **argv)
count);
return 0;
}
+ }
buf = qemu_io_alloc(count, 0xab);
--
1.7.6
- [Qemu-devel] [PULL 00/21] Block patches, Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 03/21] qemu-io: Fix if scoping bug,
Kevin Wolf <=
- [Qemu-devel] [PATCH 01/21] sheepdog: add full data preallocation support, Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 08/21] qemu-options.hx: Document missing -drive options, Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 09/21] qemu-config: Document -drive options, Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 04/21] iov: Update parameter usage in iov_(to|from)_buf(), Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 06/21] scsi-disk: Fixup debugging statement, Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 12/21] VMDK: probe for monolithicFlat images, Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 10/21] VMDK: introduce VmdkExtent, Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 11/21] VMDK: bugfix, align offset to cluster in get_whole_cluster, Kevin Wolf, 2011/07/19
- [Qemu-devel] [PATCH 05/21] scsi: Add 'hba_private' to SCSIRequest, Kevin Wolf, 2011/07/19