* [Qemu-devel] target-sh4/op.c:597: warning: cast to pointer from integer of different size
@ 2008-06-23 6:29 Jan Kiszka
2008-07-13 12:32 ` [Qemu-devel] [REMINDER] " Jan Kiszka
0 siblings, 1 reply; 2+ messages in thread
From: Jan Kiszka @ 2008-06-23 6:29 UTC (permalink / raw)
To: qemu-devel
[-- Attachment #1: Type: text/plain, Size: 606 bytes --]
The warning above pointed me to some strange code. I guess this was
originally indented:
Signed-off-by: Jan Kiszka <jan.kiszka@web.de>
Index: qemu/target-sh4/op.c
===================================================================
--- qemu.orig/target-sh4/op.c
+++ qemu/target-sh4/op.c
@@ -594,8 +594,8 @@ void OPPROTO op_shlr16_Rn(void)
void OPPROTO op_tasb_rN(void)
{
- cond_t(*(int8_t *) env->gregs[PARAM1] == 0);
- *(int8_t *) env->gregs[PARAM1] |= 0x80;
+ cond_t((env->gregs[PARAM1] & 0xff) == 0);
+ *(int8_t *) &env->gregs[PARAM1] |= 0x80;
RETURN();
}
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 254 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-07-13 12:32 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-23 6:29 [Qemu-devel] target-sh4/op.c:597: warning: cast to pointer from integer of different size Jan Kiszka
2008-07-13 12:32 ` [Qemu-devel] [REMINDER] " Jan Kiszka
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).