aboutsummaryrefslogtreecommitdiff
path: root/gdb/top.c
diff options
context:
space:
mode:
authorKevin Buettner <kevinb@redhat.com>2000-12-15 01:01:51 +0000
committerKevin Buettner <kevinb@redhat.com>2000-12-15 01:01:51 +0000
commitb8c9b27d1e133d46199734ca1f047af8bb2d3314 (patch)
tree1aa002791f0e97bfc48c64222199e6d9f9e5eb53 /gdb/top.c
parent6fa957a9b9408297206fb88e7c773931760f0528 (diff)
downloadgdb-b8c9b27d1e133d46199734ca1f047af8bb2d3314.zip
gdb-b8c9b27d1e133d46199734ca1f047af8bb2d3314.tar.gz
gdb-b8c9b27d1e133d46199734ca1f047af8bb2d3314.tar.bz2
Replace free() with xfree().
Diffstat (limited to 'gdb/top.c')
-rw-r--r--gdb/top.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/gdb/top.c b/gdb/top.c
index f80be47..a044777 100644
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -657,7 +657,7 @@ void
do_chdir_cleanup (void *old_dir)
{
chdir (old_dir);
- free (old_dir);
+ xfree (old_dir);
}
#endif
@@ -1023,7 +1023,7 @@ gdb_readline (char *prompt_arg)
if we are called again fgetc will still return EOF and
we'll return NULL then. */
break;
- free (result);
+ xfree (result);
return NULL;
}
@@ -1275,7 +1275,7 @@ command_line_input (char *prompt_arg, int repeat, char *annotation_suffix)
while (*p1)
*p++ = *p1++;
- free (rl); /* Allocated in readline. */
+ xfree (rl); /* Allocated in readline. */
if (p == linebuffer || *(p - 1) != '\\')
break;
@@ -1323,7 +1323,7 @@ command_line_input (char *prompt_arg, int repeat, char *annotation_suffix)
/* If there was an error, call this function again. */
if (expanded < 0)
{
- free (history_value);
+ xfree (history_value);
return command_line_input (prompt_arg, repeat, annotation_suffix);
}
if (strlen (history_value) > linelength)
@@ -1333,7 +1333,7 @@ command_line_input (char *prompt_arg, int repeat, char *annotation_suffix)
}
strcpy (linebuffer, history_value);
p = linebuffer + strlen (linebuffer);
- free (history_value);
+ xfree (history_value);
}
}
@@ -1574,7 +1574,7 @@ get_prompt_1 (void *data)
from bad user-supplied format string? */
sprintf (outp, fmt[0] == 0 ? default_fmt : fmt,
tmp);
- free (tmp);
+ xfree (tmp);
}
else
{
@@ -1692,7 +1692,7 @@ set_prompt (char *s)
/* ??rehrauer: I don't know why this fails, since it looks as though
assignments to prompt are wrapped in calls to savestring...
if (prompt != NULL)
- free (prompt);
+ xfree (prompt);
*/
if (event_loop_p)
PROMPT (0) = savestring (s, strlen (s));