summaryrefslogtreecommitdiff
path: root/lib/util/dlinklist.h
AgeCommit message (Collapse)AuthorFilesLines
2010-02-10util: rewrite dlinklist.h so that DLIST_ADD_END() is O(1)Andrew Tridgell1-59/+111
This changes the meaning of the ->prev pointer in our doubly linked lists to point at the end of the list from the front of the list. That allows us to implement DLIST_ADD_END() and related functions in O(1) time, which can be a huge saving in many places in Samba. This also means that the 'type' argument to various DLIST_*() macros is no longer needed, but I have left it in for now to keep the patchset small, which will make it easier to revert if any problems are found. In the future we should remove the 'type' arguments. (jra. Move the one use of DLIST_TAIL over to the new macros).
2010-02-10Temporary changes to dlinklist to keep the implementation static whilstJeremy Allison1-0/+16
uses of (list)->prev are moved over to DLIST_PREV. This will be replaced when the final (new) version of the dlinklist.h header is added. Jeremy.
2009-08-27util: fix comment and clarify argument name in DLIST_DEMOTE()Michael Adam1-3/+3
Michael
2008-10-11Remove duplicate copy of dlinklist.h.Jelmer Vernooij1-1/+1
2008-10-11Move lib/util from source4 to top-level libutil.Jelmer Vernooij1-0/+113
Conflicts: source4/Makefile