tdb2: fix prototypes which return enum TDB_ERROR.