changeset 220:2b254f02b252

Fixed off by one relocation offset for direct page external references
author lost
date Sat, 09 May 2009 16:21:54 +0000
parents 402a035220ed
children 271c0ef9ea60
files ChangeLog lwasm/insn_gen.c
diffstat 2 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sat Apr 25 04:13:52 2009 +0000
+++ b/ChangeLog	Sat May 09 16:21:54 2009 +0000
@@ -11,6 +11,11 @@
 
 Also, the software affected may follow in [].
 
+Version 2.4
+
+[!] Fixed off by one relocation offest for base page external references
+    generated by lwasm
+
 Version 2.3
 
 [*] added support for compiling using MinGW and added portions of gnulib
--- a/lwasm/insn_gen.c	Sat Apr 25 04:13:52 2009 +0000
+++ b/lwasm/insn_gen.c	Sat May 09 16:21:54 2009 +0000
@@ -102,9 +102,9 @@
 			lwasm_emitop(as, l, instab[opnum].ops[0]);
 			if (extra != -1)
 				lwasm_emit(as, l, extra);
-			lwasm_emit(as, l, v1 & 0xff);
 			l -> relocoff = as -> addr - l -> codeaddr;
 			l -> reloc8bit = 1;
+			lwasm_emit(as, l, v1 & 0xff);
 			return;
 		}
 		else