[Patch 3/4]: Rewrite of the alpha-vms bfd back-end (ld)
Nick Clifton
nickc@redhat.com
Tue Apr 13 10:53:00 GMT 2010
Hi Tristan,
A couple of minor points:
> diff --git a/ld/emultempl/vms.em b/ld/emultempl/vms.em
> new file mode 100644
> index 0000000..ec52de7
> --- /dev/null
> +++ b/ld/emultempl/vms.em
> @@ -0,0 +1,123 @@
> +# This shell script emits a C file. -*- C -*-
> +# Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
You really only need 2010 listed as a copyright year here.
> + string = (char *) xmalloc (strlen (search->name)
> + + strlen (entry->filename)
> + + sizeof "/.exe");
> +
> + sprintf (string, "%s/%s.exe", search->name, entry->filename);
What about the zero-terminator for the string ? Ie this looks like a
possible memory corruption bug to me.
Cheers
Nick
More information about the Binutils
mailing list