merge from gcc

This commit is contained in:
DJ Delorie 2002-11-24 15:59:22 +00:00
parent 931d12c681
commit 756954c3c9
2 changed files with 6 additions and 0 deletions

View file

@ -1,3 +1,8 @@
2002-11-24 Nick Clifton <nickc@redhat.com>
* make-relative-prefix.c (make_relative_prefix): Ensure return
string is empty before using strcat to construct it.
2002-11-22 Daniel Jacobowitz <drow@mvista.com> 2002-11-22 Daniel Jacobowitz <drow@mvista.com>
* Makefile.in: Add make-relative-prefix.c. * Makefile.in: Add make-relative-prefix.c.

View file

@ -362,6 +362,7 @@ make_relative_prefix (progname, bin_prefix, prefix)
return NULL; return NULL;
/* Build up the pathnames in argv[0]. */ /* Build up the pathnames in argv[0]. */
*ret = '\0';
for (i = 0; i < prog_num; i++) for (i = 0; i < prog_num; i++)
strcat (ret, prog_dirs[i]); strcat (ret, prog_dirs[i]);