On Thu, Aug 20, 2015 at 7:13 AM, Ucan, Emre (ADITG/SW1) < [email protected]> wrote:
> > Checking wl_list_empty() on a link offers no information: if it returns > true, wl_list_remove() is safe to do. If it returns false, you still do not > know if wl_list_remove() is safe; > the link could be part of a list, or the link could be "uninitialized" > (e.g. just wl_list_remove()'d). (From Pekka Paalanen's comment at > http://lists.freedesktop.org/archives/wayland-devel/2015-August/023987.html > ). > Correct me if I am wrong, but I think a more accurate statement is "if wl_list_remove() is going to crash, then wl_list_empty() is also going to crash. Therefore there is no reason to test wl_list_empty()". (by "crash" I mean "use an uninitialized pointer" but that is the usual result).
_______________________________________________ wayland-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/wayland-devel
