[olsr-dev] SPF refactoring (1) / GNU libavl import

Hannes Gredler (spam-protected)
Mon Mar 26 12:32:16 CEST 2007


On Mon, Mar 26, 2007 at 12:20:01PM +0200, Thomas Lopatic wrote:
| Hey Hannes,
| 
| [AVL tree implementation]
| 
| > ok very nice - just curious: do you have also a tree walker (that would
| > make things complete).
| 
| You mean as in "visit every tree node and execute a user-supplied
| function on the visited tree node"?

hmm - no need to do fancy callbacks ;-)
just "visit every node in a tree" and return the node.
  as a plus keep in root some sort of 'generation' counter
  which gets bumped once a node gets inserted or deleted from
  the tree. when a user function walks the tree you are able
  to detect that some other thread has altered the tree.

/hannes 




More information about the Olsr-dev mailing list