aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrediano Ziglio <freddy77@gmail.com>2011-06-20 17:08:57 +0100
committerStefan Hajnoczi <stefanha@linux.vnet.ibm.com>2011-06-20 17:08:57 +0100
commitbcd2491a48787542160d75fb7468907971b04478 (patch)
tree2d779f870fe94b989337579b032859ecba8771c4
parent77bec68668915cf9cbccf6f869e030b016b31b93 (diff)
downloadqemu-bcd2491a48787542160d75fb7468907971b04478.zip
qemu-bcd2491a48787542160d75fb7468907971b04478.tar.gz
qemu-bcd2491a48787542160d75fb7468907971b04478.tar.bz2
cmd: fix operator precedence
Signed-off-by: Frediano Ziglio <freddy77@gmail.com> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
-rw-r--r--cmd.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/cmd.c b/cmd.c
index db2c9c4..ecca167 100644
--- a/cmd.c
+++ b/cmd.c
@@ -486,7 +486,7 @@ timestr(
snprintf(ts, size, "%u:%02u.%02u",
(unsigned int) MINUTES(tv->tv_sec),
(unsigned int) SECONDS(tv->tv_sec),
- (unsigned int) usec * 100);
+ (unsigned int) (usec * 100));
return;
}
format |= VERBOSE_FIXED_TIME; /* fallback if hours needed */
@@ -497,9 +497,9 @@ timestr(
(unsigned int) HOURS(tv->tv_sec),
(unsigned int) MINUTES(tv->tv_sec),
(unsigned int) SECONDS(tv->tv_sec),
- (unsigned int) usec * 100);
+ (unsigned int) (usec * 100));
} else {
- snprintf(ts, size, "0.%04u sec", (unsigned int) usec * 10000);
+ snprintf(ts, size, "0.%04u sec", (unsigned int) (usec * 10000));
}
}