Re: GLib bug - GRelation



"Michal Burda" <michal burda centrum cz> writes:
> 
> in file grel.c, function g_relation_select():
> 
> ...
> GRealTuples *tuples = g_new0(GRealTuples, 1);
> ...
> g_return_val_if_fail(relation != NULL, NULL);
> ...
> 
> what if relation will really be NULL! Some memory allocated 
> before (tuples) will lost, isn't it!
> 

Yes, state is not guaranteed to be correct after a g_return_if_fail()
- g_return_if_fail() means "your program is broken, we are kindly
warning you about it, but the error is unrecoverable."

Havoc




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]