From 7295e9856dea66699f84eb95038919d33710b170 Mon Sep 17 00:00:00 2001 From: Keith Kanios Date: Wed, 18 Apr 2007 02:24:34 +0000 Subject: [PATCH] Fixed RDF/2 to comply with "maxbits" use. --- output/outrdf.c | 3 ++- output/outrdf2.c | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/output/outrdf.c b/output/outrdf.c index 3c726520..cd311de5 100644 --- a/output/outrdf.c +++ b/output/outrdf.c @@ -194,6 +194,7 @@ static int32_t bsslength; static void rdf_init(FILE * fp, efunc errfunc, ldfunc ldef, evalfunc eval) { + maxbits = 64; ofile = fp; error = errfunc; seg[0] = newmembuf(); @@ -423,7 +424,7 @@ static void rdf_out(int32_t segto, void *data, uint32_t type, membufwrite(seg[segto], &rr.offset, -2); } else if (type == OUT_REL4ADR) { - if (segment == segto) + if ((segment == segto) && (globalbits != 64)) error(ERR_PANIC, "intra-segment OUT_REL4ADR"); if (segment != NO_SEG && segment % 2) { error(ERR_NONFATAL, diff --git a/output/outrdf2.c b/output/outrdf2.c index 9fa21532..7fb46159 100644 --- a/output/outrdf2.c +++ b/output/outrdf2.c @@ -88,6 +88,8 @@ static void rdf2_init(FILE * fp, efunc errfunc, ldfunc ldef, evalfunc eval) (void)ldef; (void)eval; + maxbits = 64; + int segtext, segdata, segbss; /* set up the initial segments */ @@ -624,7 +626,7 @@ static void rdf2_out(int32_t segto, const void *data, uint32_t type, membufwrite(segto, &rr.offset, -2); } else if (type == OUT_REL4ADR) { - if (segment == segto) + if ((segment == segto) && (globalbits != 64)) error(ERR_PANIC, "intra-segment OUT_REL4ADR"); if (segment != NO_SEG && segment % 2) { error(ERR_PANIC, "erm... 4 byte segment base ref?"); -- 2.11.4.GIT