aboutsummaryrefslogtreecommitdiff
path: root/gcc/java/jcf-path.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2008-06-24 12:46:59 +0000
committerTom Tromey <tromey@redhat.com>2008-06-24 12:46:59 +0000
commit6497fb4a253f3b14cb2f8b4c1c715696d6e65f95 (patch)
tree354f09c5b595364bbe3a120012deb913cb611a72 /gcc/java/jcf-path.c
parent3076ed43e640f122af4cd9a3790f7f9231ab4d2e (diff)
* jcf-path.c (jcf_path_init): Don't name variable 'try'.
* expr.c (add_type_assertion): Rename argument. (build_java_arrayaccess): Don't name variable 'throw'. (ARRAY_NEW_MULTI): Don't name variable 'class'. * jcf-io.c (find_class): Don't name variable 'class'. * mangle.c (compression_table_add): Don't name variable 'new'. * constants.c (cpool_for_class): Rename argument. (alloc_constant_fieldref): Likewise. * jcf-parse.c (handle_innerclass_attribute): Don't name variable 'class'. (read_class): Likewise. (parse_zip_file_entries): Likewise. (process_zip_dir): Likewise. * decl.c (java_mark_class_local): Rename argument. * class.c (GEN_TABLE): Use type_name, not typename. (gen_indirect_dispatch_tables): Likewise. (add_field): Rename argument. (is_compiled_class): Likewise. (safe_layout_class): Likewise. (emit_assertion_table): Likewise. * typeck.c (has_method): Rename argument. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@137069 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/java/jcf-path.c')
-rw-r--r--gcc/java/jcf-path.c76
1 files changed, 38 insertions, 38 deletions
diff --git a/gcc/java/jcf-path.c b/gcc/java/jcf-path.c
index ca7875ce30f..7e21770ec51 100644
--- a/gcc/java/jcf-path.c
+++ b/gcc/java/jcf-path.c
@@ -1,6 +1,6 @@
/* Handle CLASSPATH, -classpath, and path searching.
Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2006,
- 2007 Free Software Foundation, Inc.
+ 2007, 2008 Free Software Foundation, Inc.
This file is part of GCC.
@@ -213,7 +213,7 @@ void
jcf_path_init (void)
{
char *cp;
- char *try, sep[2];
+ char *attempt, sep[2];
struct stat stat_b;
int found = 0, len;
@@ -227,56 +227,56 @@ jcf_path_init (void)
GET_ENVIRONMENT (cp, "GCC_EXEC_PREFIX");
if (cp)
{
- try = (char *) alloca (strlen (cp) + 50);
+ attempt = (char *) alloca (strlen (cp) + 50);
/* The exec prefix can be something like
/usr/local/bin/../lib/gcc-lib/. We want to change this
into a pointer to the share/java directory. We support two
configurations: one where prefix and exec-prefix are the
same, and one where exec-prefix is `prefix/SOMETHING'. */
- strcpy (try, cp);
- strcat (try, DIR_UP);
- strcat (try, sep);
- strcat (try, DIR_UP);
- strcat (try, sep);
- len = strlen (try);
-
- strcpy (try + len, "share");
- strcat (try, sep);
- strcat (try, "java");
- strcat (try, sep);
- strcat (try, "libgcj-" DEFAULT_TARGET_VERSION ".jar");
- if (! stat (try, &stat_b))
+ strcpy (attempt, cp);
+ strcat (attempt, DIR_UP);
+ strcat (attempt, sep);
+ strcat (attempt, DIR_UP);
+ strcat (attempt, sep);
+ len = strlen (attempt);
+
+ strcpy (attempt + len, "share");
+ strcat (attempt, sep);
+ strcat (attempt, "java");
+ strcat (attempt, sep);
+ strcat (attempt, "libgcj-" DEFAULT_TARGET_VERSION ".jar");
+ if (! stat (attempt, &stat_b))
{
- add_entry (&sys_dirs, try, 1);
+ add_entry (&sys_dirs, attempt, 1);
found = 1;
- strcpy (&try[strlen (try)
- - strlen ("libgcj-" DEFAULT_TARGET_VERSION ".jar")],
+ strcpy (&attempt[strlen (attempt)
+ - strlen ("libgcj-" DEFAULT_TARGET_VERSION ".jar")],
sep);
- strcat (try, "ext");
- strcat (try, sep);
- if (! stat (try, &stat_b))
- jcf_path_extdirs_arg (try);
+ strcat (attempt, "ext");
+ strcat (attempt, sep);
+ if (! stat (attempt, &stat_b))
+ jcf_path_extdirs_arg (attempt);
}
else
{
- strcpy (try + len, DIR_UP);
- strcat (try, sep);
- strcat (try, "share");
- strcat (try, sep);
- strcat (try, "java");
- strcat (try, sep);
- strcat (try, "libgcj-" DEFAULT_TARGET_VERSION ".jar");
- if (! stat (try, &stat_b))
+ strcpy (attempt + len, DIR_UP);
+ strcat (attempt, sep);
+ strcat (attempt, "share");
+ strcat (attempt, sep);
+ strcat (attempt, "java");
+ strcat (attempt, sep);
+ strcat (attempt, "libgcj-" DEFAULT_TARGET_VERSION ".jar");
+ if (! stat (attempt, &stat_b))
{
- add_entry (&sys_dirs, try, 1);
+ add_entry (&sys_dirs, attempt, 1);
found = 1;
- strcpy (&try[strlen (try)
- - strlen ("libgcj-" DEFAULT_TARGET_VERSION ".jar")],
+ strcpy (&attempt[strlen (attempt)
+ - strlen ("libgcj-" DEFAULT_TARGET_VERSION ".jar")],
sep);
- strcat (try, "ext");
- strcat (try, sep);
- if (! stat (try, &stat_b))
- jcf_path_extdirs_arg (try);
+ strcat (attempt, "ext");
+ strcat (attempt, sep);
+ if (! stat (attempt, &stat_b))
+ jcf_path_extdirs_arg (attempt);
}
}
}