This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[PATCH]: missing check in gas/app.c
- From: Arnold Metselaar <arnold dot metselaar at planet dot nl>
- To: binutils at sources dot redhat dot com
- Date: Tue, 13 Sep 2005 22:41:09 +0200
- Subject: [PATCH]: missing check in gas/app.c
Hello
While working on as for target Z80, I noticed that a check for a
full buffer was missing after an optimised copy in
do_scrub_chars() in gas/app.c
A patch is below, it works with the assembler for Z80.
Side note: I sent the copyright assignment for binutils to FSF,
but I haven't heard from them yet.
Arnold Metselaar
*** src/gas/app.c 2005-05-05 11:12:43.000000000 +0200
--- src/gas/app.c.new 2005-09-13 22:24:44.000000000 +0200
***************
*** 1302,1307 ****
--- 1302,1310 ----
case 1: *to++ = *from++;
}
}
+ /* normally tested in PUT() */
+ if (to >= toend)
+ goto tofull;
ch = GET ();
}
}