mirror of
https://github.com/radareorg/radare2.git
synced 2025-01-30 01:44:50 +00:00
fix XCHG output while memory access (#4732)
This commit is contained in:
parent
f8c7c8a95b
commit
e9efad51e4
@ -1142,14 +1142,26 @@ Sets the byte in the operand to 1 if the Sign Flag is not equal
|
||||
{
|
||||
char *src = getarg (&gop, 1, 0, NULL); // x
|
||||
char *dst = getarg (&gop, 0, 0, NULL); // y
|
||||
esilprintf (op,
|
||||
"%s,%s,^,%s,=,"
|
||||
"%s,%s,^,%s,=,"
|
||||
"%s,%s,^,%s,=,",
|
||||
dst, src, src, // x = x ^ y
|
||||
src, dst, dst, // y = y ^ x
|
||||
dst, src, src); // x = x ^ y
|
||||
//esilprintf (op, "%s,%s,%s,=,%s", src, dst, src, dst);
|
||||
if (INSOP(0).type == X86_OP_MEM) {
|
||||
char *dst1 = getarg (&gop, 0, 1, NULL);
|
||||
esilprintf (op,
|
||||
"%s,%s,^,%s,=,"
|
||||
"%s,%s,^,%s,"
|
||||
"%s,%s,^,%s,=",
|
||||
dst, src, src, // x = x ^ y
|
||||
src, dst, dst1, // y = y ^ x
|
||||
dst, src, src); // x = x ^ y
|
||||
free (dst1);
|
||||
} else {
|
||||
esilprintf (op,
|
||||
"%s,%s,^,%s,=,"
|
||||
"%s,%s,^,%s,=,"
|
||||
"%s,%s,^,%s,=",
|
||||
dst, src, src, // x = x ^ y
|
||||
src, dst, dst, // y = y ^ x
|
||||
dst, src, src); // x = x ^ y
|
||||
//esilprintf (op, "%s,%s,%s,=,%s", src, dst, src, dst);
|
||||
}
|
||||
free (src);
|
||||
free (dst);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user