convert to use of variable arg count concat() in libiberty.
+Tue Nov 12 09:40:07 1991 Fred Fish (fnf at cygnus.com)
+
+ * utils.c, rem-multi.shar: Remove fixed arg count version of
+ concat().
+
+ * altos-xdep.c, arm-xdep.c, coffread.c, command.c, convex-xdep.c,
+ core.c, dwarfread.c, gould-xdep.c, infcmd.c, language.c,
+ m88k-xdep.c, main.c, printcmd.c, pyr-xdep.c, source.c,
+ sun386-xdep.c, symm-xdep.c, umax-xdep.c, values.c, xcoffread.c:
+ Change all instances of use of fixed args concat() to variable
+ args concat() now located in libiberty.
+
Tue Nov 12 07:23:46 1991 John Gilmore (gnu at cygnus.com)
* Makefile.in: Add xcoffread.c, xcoffexec.c.
corefile = savestring (filename, strlen (filename));
else
{
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
}
set_current_frame ( create_new_frame (read_register (FP_REGNUM),
corefile = savestring (filename, strlen (filename));
else
{
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
}
set_current_frame ( create_new_frame (read_register (FP_REGNUM),
{
if (TYPE_NAME (target))
free (TYPE_NAME (target));
- TYPE_NAME (target) = concat (TYPE_NAME (real_target), "", "");
+ TYPE_NAME (target) = concat (TYPE_NAME (real_target), NULL);
}
}
if (TYPE_NAME (SYMBOL_TYPE (sym)) == 0
&& (TYPE_FLAGS (SYMBOL_TYPE (sym)) & TYPE_FLAG_PERM) == 0)
TYPE_NAME (SYMBOL_TYPE (sym))
- = concat (SYMBOL_NAME (sym), "", "");
+ = concat (SYMBOL_NAME (sym), NULL);
/* Keep track of any type which points to empty structured type,
so it can be filled from a definition from another file */
? "enum "
: (cs->c_sclass == C_STRTAG
? "struct " : "union ")),
- SYMBOL_NAME (sym));
+ SYMBOL_NAME (sym), NULL);
add_symbol_to_list (sym, &file_symbols);
break;
/* anonymous structure type */
type = coff_alloc_type (cs->c_symnum);
TYPE_CODE (type) = TYPE_CODE_STRUCT;
- TYPE_NAME (type) = concat ("struct ", "<opaque>", "");
+ TYPE_NAME (type) = concat ("struct ", "<opaque>", NULL);
TYPE_LENGTH (type) = 0;
TYPE_FIELDS (type) = 0;
TYPE_NFIELDS (type) = 0;
{
/* anonymous union type */
type = coff_alloc_type (cs->c_symnum);
- TYPE_NAME (type) = concat ("union ", "<opaque>", "");
+ TYPE_NAME (type) = concat ("union ", "<opaque>", NULL);
TYPE_LENGTH (type) = 0;
TYPE_FIELDS (type) = 0;
TYPE_NFIELDS (type) = 0;
/* Replace "set " at start of docstring with "show ". */
if (setcmd->doc[0] == 'S' && setcmd->doc[1] == 'e'
&& setcmd->doc[2] == 't' && setcmd->doc[3] == ' ')
- showcmd->doc = concat ("Show ", setcmd->doc + 4, "");
+ showcmd->doc = concat ("Show ", setcmd->doc + 4, NULL);
else
fprintf (stderr, "GDB internal error: Bad docstring for set command\n");
if (filename[0] == '/')
corefile = savestring (filename, strlen (filename));
else
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
printf_filtered ("Program %s ", u.u_comm);
filename = tilde_expand (filename);
if (filename[0] != '/') {
- temp = concat (current_directory, "/", filename);
+ temp = concat (current_directory, "/", filename, NULL);
free (filename);
filename = temp;
}
TYPE_LENGTH (type) = dip -> at_byte_size;
tpart3 = "";
}
- TYPE_NAME (type) = concat (tpart1, tpart2, tpart3);
+ TYPE_NAME (type) = concat (tpart1, tpart2, tpart3, NULL);
thisdie += dip -> dielength;
while (thisdie < enddie)
{
TYPE_LENGTH (type) = dip -> at_byte_size;
tpart3 = "";
}
- TYPE_NAME (type) = concat (tpart1, tpart2, tpart3);
+ TYPE_NAME (type) = concat (tpart1, tpart2, tpart3, NULL);
if ((scan = dip -> at_element_list) != NULL)
{
(void) memcpy (&temp, scan, sizeof (temp));
corefile = savestring (filename, strlen (filename));
else
{
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
}
set_current_frame ( create_new_frame (read_register (FP_REGNUM),
if (language_mode == language_mode_auto)
prefix = "auto; currently ";
- language = concat(prefix, current_language->la_name, "");
+ language = concat(prefix, current_language->la_name, NULL);
}
void
error ("Unrecognized type check setting.");
}
- type = concat(prefix,tmp,"");
+ type = concat(prefix,tmp,NULL);
}
void
error ("Unrecognized range check setting.");
}
- range = concat(pref,tmp,"");
+ range = concat(pref,tmp,NULL);
}
corefile = savestring (filename, strlen (filename));
else
{
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
}
init_tdesc();
current_context = init_dcontext();
corefile = savestring (filename, strlen (filename));
else
{
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
}
#if 1 || defined(PYRAMID_CONTROL_FRAME_DEBUGGING)
return p;
}
-char *
-concat (s1, s2, s3)
- char *s1, *s2, *s3;
-{
- register int len = strlen (s1) + strlen (s2) + strlen (s3) + 1;
- register char *val = (char *) xmalloc (len);
- strcpy (val, s1);
- strcat (val, s2);
- strcat (val, s3);
- return val;
-}
-
void
print_spaces (n, file)
register int n;
corefile = savestring (filename, strlen (filename));
else
{
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
}
set_current_frame ( create_new_frame (read_register (FP_REGNUM),
corefile = savestring (filename, strlen (filename));
else
{
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
}
set_current_frame(create_new_frame(read_register(FP_REGNUM),
corefile = savestring (filename, strlen (filename));
else
{
- corefile = concat (current_directory, "/", filename);
+ corefile = concat (current_directory, "/", filename, NULL);
}
set_current_frame ( create_new_frame (read_register (FP_REGNUM),
return var;
var = (struct internalvar *) xmalloc (sizeof (struct internalvar));
- var->name = concat (name, "", "");
+ var->name = concat (name, NULL);
var->value = allocate_value (builtin_type_void);
release_value (var->value);
var->next = internalvars;
TYPE_NAME (ttype) = concat (
TYPE_CODE (ttype) == TYPE_CODE_UNION ? "union " :
TYPE_CODE (ttype) == TYPE_CODE_STRUCT? "struct " : "enum ",
- SYMBOL_NAME (sym), "");
+ SYMBOL_NAME (sym), NULL);
else if (!TYPE_NAME (ttype)) /* else, regular typedef. */
TYPE_NAME (ttype) = SYMBOL_NAME (sym);