Hi Rob,

 You have modified llist_free to llist_traverse().

In llist_traverse()

while (list) {
        void *pop = llist_pop(&list);
        using(pop);

        // End doubly linked list too.
        if (list==pop) break;
    }

'using' is used without checking it. This is potential crash, if NULL
is passed to llist_tarverse().

I do understand that, why should someone make a call to traverse, if
not wanting to use the elements. But for a safe programming, I think
checking the variable would be better.

For dirtree_path(), I had requested you earlier also, can we modify
the '/' appending logic to append the '/' only in case its not there
at the end else its fine.
Like,
if (len) {
        if(path[len -1] != '/') path[len++]='/';
    }

please do let me know your opinion.

-Ashwini
_______________________________________________
Toybox mailing list
[email protected]
http://lists.landley.net/listinfo.cgi/toybox-landley.net

Reply via email to