From owner-freebsd-bugs Sat Sep 19 06:50:25 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id GAA06417 for freebsd-bugs-outgoing; Sat, 19 Sep 1998 06:50:25 -0700 (PDT) (envelope-from owner-freebsd-bugs@FreeBSD.ORG) Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id GAA06410 for ; Sat, 19 Sep 1998 06:50:24 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.8.8/8.8.5) id GAA04810; Sat, 19 Sep 1998 06:50:01 -0700 (PDT) Date: Sat, 19 Sep 1998 06:50:01 -0700 (PDT) Message-Id: <199809191350.GAA04810@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.ORG From: Doug Rabson Subject: Re: bin/7980: New ld buggy! Reply-To: Doug Rabson Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org The following reply was made to PR bin/7980; it has been noted by GNATS. From: Doug Rabson To: Joakim Henriksson Cc: FreeBSD-gnats-submit@freebsd.org Subject: Re: bin/7980: New ld buggy! Date: Sat, 19 Sep 1998 14:40:39 +0100 (BST) Please try this patch to src/contrib/binutils/bfd which at least fixes the test case in the bug report: Index: elflink.h =================================================================== RCS file: /home/ncvs/src/contrib/binutils/bfd/elflink.h,v retrieving revision 1.1.1.2 diff -u -r1.1.1.2 elflink.h --- elflink.h 1998/09/06 22:57:08 1.1.1.2 +++ elflink.h 1998/09/19 10:18:46 @@ -719,12 +719,14 @@ } sz = bfd_section_size (abfd, s); - msg = (char *) bfd_alloc (abfd, sz); + msg = (char *) bfd_alloc (abfd, sz+1); if (msg == NULL) goto error_return; if (! bfd_get_section_contents (abfd, s, msg, (file_ptr) 0, sz)) goto error_return; + + msg[sz] = '\0'; if (! (_bfd_generic_link_add_one_symbol (info, abfd, name, BSF_WARNING, s, (bfd_vma) 0, msg, -- Doug Rabson Mail: dfr@nlsystems.com Nonlinear Systems Ltd. Phone: +44 181 951 1891 Fax: +44 181 381 1039 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message