changeset 309:34203598be6d

Fixed reading object file incomplete references table
author lost
date Fri, 23 Jan 2009 05:49:16 +0000
parents ecc092adc0be
children 3476629ee0ce
files src/readfiles.c
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/readfiles.c	Fri Jan 23 05:10:33 2009 +0000
+++ b/src/readfiles.c	Fri Jan 23 05:49:16 2009 +0000
@@ -272,6 +272,14 @@
 				lw_expr_stack_push(rp -> expr, term);
 				lw_expr_term_free(term);
 			}
+			// skip the NUL
+			NEXTBYTE();
+			
+			// fetch the offset
+			rp -> offset = CURBYTE() << 8;
+			NEXTBYTE();
+			rp -> offset |= CURBYTE() & 0xff;
+			NEXTBYTE();
 		}
 		// skip the NUL terminating the relocations
 		NEXTBYTE();