]> git.ipfire.org Git - thirdparty/bash.git/blobdiff - lib/readline/tilde.c
Imported from ../bash-2.01.1.tar.gz.
[thirdparty/bash.git] / lib / readline / tilde.c
index 1d38d9d461f349b6f9f211d9c5032cba426cec0f..fe263a2605c761a0103b64ea96b8eef0e4dbbf9f 100644 (file)
@@ -189,7 +189,7 @@ tilde_expand (string)
   if (result = strchr (string, '~'))
     result = xmalloc (result_size = (strlen (string) + 16));
   else
-    result = xmalloc (result_size = strlen (string));
+    result = xmalloc (result_size = (strlen (string) + 1));
 
   /* Scan through STRING expanding tildes as we come to them. */
   while (1)