Switched out calls to g_error() for calls to complain().

This commit is contained in:
Pietro Gagliardi 2015-04-18 17:23:36 -04:00
parent 1abd5ebb4c
commit d0c0188ef9
3 changed files with 4 additions and 8 deletions

View File

@ -170,8 +170,7 @@ static void onDestroy(GtkWidget *widget, gpointer data)
singleWidget *s = (singleWidget *) data;
if (!s->canDestroy)
// TODO switch to complain()
g_error("trying to destroy control with singleWidget at %p before uiControlDestroy()", s);
complain("trying to destroy control with singleWidget at %p before uiControlDestroy()", s);
uiFree(s);
}

View File

@ -44,8 +44,7 @@ static void uipParent_dispose(GObject *obj)
// don't free mainControl here; that should have been done by uiParentDestroy()
if (!p->canDestroy)
// TODO switch to complain()
g_error("attempt to dispose uiParent with uipParent at %p before uiParentDestroy()", p);
complain("attempt to dispose uiParent with uipParent at %p before uiParentDestroy()", p);
if (p->children != NULL) {
g_ptr_array_unref(p->children);
p->children = NULL;
@ -58,8 +57,7 @@ static void uipParent_finalize(GObject *obj)
uipParent *p = uipParent(obj);
if (!p->canDestroy)
// TODO switch to complain()
g_error("attempt to finalize uiParent with uipParent at %p before uiParentDestroy()", p);
complain("attempt to finalize uiParent with uipParent at %p before uiParentDestroy()", p);
G_OBJECT_CLASS(uipParent_parent_class)->finalize(obj);
if (options.debugLogAllocations)
fprintf(stderr, "%p free\n", obj);

View File

@ -33,8 +33,7 @@ static void onDestroy(GtkWidget *widget, gpointer data)
struct window *w = (struct window *) data;
if (!w->canDestroy)
// TODO switch to complain()
g_error("attempt to dispose uiWindow at %p before uiWindowDestroy()", w);
complain("attempt to dispose uiWindow at %p before uiWindowDestroy()", w);
uiFree(w);
}