[FFmpeg-cvslog] r11391 - trunk/libavutil/tree.c
michael
subversion
Fri Jan 4 11:14:22 CET 2008
Author: michael
Date: Fri Jan 4 11:14:21 2008
New Revision: 11391
Log:
Always set next correctly, even if a matching element is found (thats
how its documented and used).
Modified:
trunk/libavutil/tree.c
Modified: trunk/libavutil/tree.c
==============================================================================
--- trunk/libavutil/tree.c (original)
+++ trunk/libavutil/tree.c Fri Jan 4 11:14:21 2008
@@ -35,6 +35,10 @@ void *av_tree_find(const AVTreeNode *t,
if(next) next[(v>>31)^1]= t->elem;
return av_tree_find(t->child[v>>31], key, cmp, next);
}else{
+ if(next){
+ av_tree_find(t->child[0], key, cmp, next);
+ av_tree_find(t->child[1], key, cmp, next);
+ }
return t->elem;
}
}
More information about the ffmpeg-cvslog
mailing list