timy error in tracerse.c ?

simo idra at samba.org
Wed Mar 1 15:43:00 GMT 2006

In lib/tdb/common/traverse.c, line 178 we have the following code:

                if (fn && fn(tdb, key, dbuf, private)) {
                        /* They want us to terminate traversal */
                        ret = count;
                        if (tdb_unlock_record(tdb, tl->off) != 0) {
                                TDB_LOG((tdb, 0, "tdb_traverse:
unlock_record failed!\n"));;
                                ret = -1;
                        tdb->travlocks.next = tl->next;
                        return count;

it seem to me that
	return count;
is wrong and that should be
	return ret;

Should I commit a fix? Or is there something I'm not understanding ?


Simo Sorce
Samba Team GPL Compliance Officer
email: idra at samba.org

More information about the samba-technical mailing list