Commit 9a9864f8 authored by Morten Welinder's avatar Morten Welinder Committed by Morten Welinder

Ignore NULLs.

2000-01-05  Morten Welinder  <terra@diku.dk>

	* src/parser.y (register_allocation, unregister_allocation):
 	Ignore NULLs.
parent 749b89f0
2000-01-03 Morten Welinder <terra@diku.dk>
2000-01-05 Morten Welinder <terra@diku.dk>
* src/parser.y (register_allocation, unregister_allocation):
Ignore NULLs.
2000-01-04 Morten Welinder <terra@diku.dk>
* parser.y: revamp the allocation and deallocation system.
......@@ -6,9 +11,6 @@
* src/solver-lp.c (solver_simplex): j not used.
* src/cell.c (cell_cleanout): Not static since prototyped in
cell.h.
2000-01-04 Jody Goldberg <jgoldberg@home.com>
* src/commands.[ch] : New files.
......
2000-01-03 Morten Welinder <terra@diku.dk>
2000-01-05 Morten Welinder <terra@diku.dk>
* src/parser.y (register_allocation, unregister_allocation):
Ignore NULLs.
2000-01-04 Morten Welinder <terra@diku.dk>
* parser.y: revamp the allocation and deallocation system.
......@@ -6,9 +11,6 @@
* src/solver-lp.c (solver_simplex): j not used.
* src/cell.c (cell_cleanout): Not static since prototyped in
cell.h.
2000-01-04 Jody Goldberg <jgoldberg@home.com>
* src/commands.[ch] : New files.
......
......@@ -68,7 +68,7 @@ cell_cleanout (Cell *cell)
}
void
static void
cell_set_formula (Cell *cell, const char *text)
{
ExprTree *new_expr;
......
......@@ -112,7 +112,13 @@ deallocate_assert_empty (void)
static void *
register_allocation (void *data, ParseDeallocator freer)
{
AllocRec *rec = g_new (AllocRec, 1);
AllocRec *rec;
/* It's handy to be able to register and unregister NULLs. */
if (!data)
return;
rec = g_new (AllocRec, 1);
rec->data = data;
rec->freer = freer;
alloc_list = g_list_prepend (alloc_list, rec);
......@@ -133,6 +139,10 @@ unregister_allocation (const void *data)
{
GList *l;
/* It's handy to be able to register and unregister NULLs. */
if (!data)
return;
for (l = alloc_list; l; l = l->next) {
AllocRec *rec = l->data;
if (rec->data == data) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment