summaryrefslogtreecommitdiffstats
path: root/lib/tdb2/check.c
Commit message (Collapse)AuthorAgeFilesLines
* tdb2: fix prototypes which return enum TDB_ERROR.Rusty Russell2011-09-141-1/+1
| | | | | | | | | | Since enums and ints are compatible in C, the compiler didn't warn that our prototypes for these functions disagreed with the definitions. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (Imported from CCAN commit 6d3832ee613adeb9ae7ed6454996ffa39c32650f)
* tdb2: add error conversion functions.Rusty Russell2011-09-141-5/+5
| | | | | | | | | | This clarifies the code a little, but also provides a more explicit mechanism which can be used to debug error handling (by introducing tdb_err_t and making it a pointer type). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (Imported from CCAN commit afa6d57b7d93fe4675a952f556eb462951baa257)
* tdb2: unify tdb1_check and tdb1_summary into tdb_check and tdb_summary.Rusty Russell2011-09-141-0/+6
| | | | | | | | Switch on the TDB_VERSION1 flag. Also, change tdb1_check's checkfn argument to return an error code (and set tdb->last_error accordingly). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (Imported from CCAN commit ef92843f2c74ab9d4fa7f167a2182e5e8955df91)
* tdb2: merge tdb1_context into tdb_context.Rusty Russell2011-09-141-2/+2
| | | | | | | | | | Finally, we split out the tdb2-specific parts of tdb_context, and put them into a "tdb2" sub-struct; the tdb1 parts go into a "tdb1" sub-struct. We get rido of tdb1_context and use tdb_context everywhere. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (Imported from CCAN commit bbeb528e74c0e234e1f724ac8d54be404cfc6f9a)
* tdb2: add lib/tdb2 (from CCAN init-1161-g661d41f)Rusty Russell2011-06-201-0/+835
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>