summaryrefslogtreecommitdiff
path: root/gcc/java/jcf-path.c
diff options
context:
space:
mode:
authorhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>2002-06-08 16:34:39 +0000
committerhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>2002-06-08 16:34:39 +0000
commit2b9fe084feca0dc81274297507683aef4a2e243f (patch)
treed839c8487cf59d908a49b9dfadce5982f84bce1e /gcc/java/jcf-path.c
parent6d54596a6a1f1b14f571102a0a3528d8a162e974 (diff)
downloadgcc-2b9fe084feca0dc81274297507683aef4a2e243f.tar.gz
2002-06-08 H.J. Lu (hjl@gnu.org)
* jcf-path.c (jcf_path_init): Allocate 1 more byte for string. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54384 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/java/jcf-path.c')
-rw-r--r--gcc/java/jcf-path.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/java/jcf-path.c b/gcc/java/jcf-path.c
index a87703e5ac0..b68a538f45b 100644
--- a/gcc/java/jcf-path.c
+++ b/gcc/java/jcf-path.c
@@ -305,7 +305,7 @@ jcf_path_init ()
/* Desperation: use the installed one. */
char *extdirs;
add_entry (&sys_dirs, LIBGCJ_ZIP_FILE, 1);
- extdirs = (char *) alloca (strlen (LIBGCJ_ZIP_FILE));
+ extdirs = (char *) alloca (strlen (LIBGCJ_ZIP_FILE) + 1);
strcpy (extdirs, LIBGCJ_ZIP_FILE);
strcpy (&extdirs[strlen (LIBGCJ_ZIP_FILE)
- strlen ("libgcj-" DEFAULT_TARGET_VERSION ".jar")],