Replace FREEIF() with xfree().
This commit is contained in:
parent
cd17328aad
commit
8038e1e2b1
|
@ -1,3 +1,9 @@
|
||||||
|
Thu Jan 18 12:25:06 2001 Andrew Cagney <cagney@b1.cygnus.com>
|
||||||
|
|
||||||
|
* varobj.c (FREEIF): Delete macro.
|
||||||
|
(varobj_set_value, free_variable): Replace FREEIF with ``xfree''
|
||||||
|
call.
|
||||||
|
|
||||||
2001-01-18 Nick Clifton <nickc@redhat.com>
|
2001-01-18 Nick Clifton <nickc@redhat.com>
|
||||||
|
|
||||||
* arc-tdep.c (arc_cpu_type_table): Add new arc core numbers.
|
* arc-tdep.c (arc_cpu_type_table): Add new arc core numbers.
|
||||||
|
|
15
gdb/varobj.c
15
gdb/varobj.c
|
@ -391,11 +391,6 @@ static int rootcount = 0; /* number of root varobjs in the list */
|
||||||
/* Pointer to the varobj hash table (built at run time) */
|
/* Pointer to the varobj hash table (built at run time) */
|
||||||
static struct vlist **varobj_table;
|
static struct vlist **varobj_table;
|
||||||
|
|
||||||
#if defined(FREEIF)
|
|
||||||
#undef FREEIF
|
|
||||||
#endif
|
|
||||||
#define FREEIF(x) if (x != NULL) free((char *) (x))
|
|
||||||
|
|
||||||
/* Is the variable X one of our "fake" children? */
|
/* Is the variable X one of our "fake" children? */
|
||||||
#define CPLUS_FAKE_CHILD(x) \
|
#define CPLUS_FAKE_CHILD(x) \
|
||||||
((x) != NULL && (x)->type == NULL && (x)->value == NULL)
|
((x) != NULL && (x)->type == NULL && (x)->value == NULL)
|
||||||
|
@ -788,7 +783,7 @@ varobj_set_value (struct varobj *var, char *expression)
|
||||||
if (!gdb_evaluate_expression (exp, &value))
|
if (!gdb_evaluate_expression (exp, &value))
|
||||||
{
|
{
|
||||||
/* We cannot proceed without a valid expression. */
|
/* We cannot proceed without a valid expression. */
|
||||||
FREEIF (exp);
|
xfree (exp);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1353,12 +1348,12 @@ free_variable (struct varobj *var)
|
||||||
if (var->root->rootvar == var)
|
if (var->root->rootvar == var)
|
||||||
{
|
{
|
||||||
free_current_contents ((char **) &var->root->exp);
|
free_current_contents ((char **) &var->root->exp);
|
||||||
FREEIF (var->root);
|
xfree (var->root);
|
||||||
}
|
}
|
||||||
|
|
||||||
FREEIF (var->name);
|
xfree (var->name);
|
||||||
FREEIF (var->obj_name);
|
xfree (var->obj_name);
|
||||||
FREEIF (var);
|
xfree (var);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in New Issue