2004-04-09 James Willcox <james@ximian.com>
authorJames Willcox <jwilcox@mono-cvs.ximian.com>
Sat, 9 Apr 2005 18:48:44 +0000 (18:48 -0000)
committerJames Willcox <jwilcox@mono-cvs.ximian.com>
Sat, 9 Apr 2005 18:48:44 +0000 (18:48 -0000)
        * template.c: allocate the correct amount of memory for newargs

svn path=/trunk/mcs/; revision=42737

mcs/tools/mkbundle/ChangeLog
mcs/tools/mkbundle/template.c

index c7042aa8a1b5b53cd937aa7f478bd4c888b1e051..809c442a64651f7e543e11bcec1b1916525cc2f2 100644 (file)
@@ -1,3 +1,7 @@
+2004-04-09  James Willcox  <james@ximian.com>
+
+       * template.c: allocate the correct amount of memory for newargs
+
 2005-04-08  Miguel de Icaza  <miguel@novell.com>
 
        * mkbundle.cs: Add support for bundling also a machine.config
index df94312a9d98cbbbe0599b8acded0d72dbf3748f..2f0bca5e39ca8d94939b8f11cde76c44d4a5b588 100644 (file)
@@ -4,7 +4,7 @@ int mono_main (int argc, char* argv[]);
 
 int main (int argc, char* argv[])
 {
-       char **newargs = (char **) malloc (sizeof (char *) * argc + 2);
+       char **newargs = (char **) malloc (sizeof (char *) * (argc + 2));
        int i;
 
        newargs [0] = argv [0];