summaryrefslogtreecommitdiffstats
path: root/source/lib/util_tdb.c
Commit message (Collapse)AuthorAgeFilesLines
* r23981: Make tdb_validate_and_backup try harder to end up with a valid tdb:Michael Adam2007-07-201-23/+60
| | | | | | | | | If restoring a backup fails due to lack of space, remove the corrupt tdb previously moved away to "name.corrupt", and retry. If restoring still fails, move the backup in place instead of copying it. Michael
* r23975: Enhance some debug output.Michael Adam2007-07-191-2/+4
|
* r23957: Use tdb_open_log instead of tdb_open.Michael Adam2007-07-181-6/+6
| | | | Michael
* r23952: Streamline and improve the logic of tdb_validate_and backup:Michael Adam2007-07-181-29/+63
| | | | | | | | | | | | | | | | | | | | | | | - call tdb_validate on the given tdb. - if validation is successful, create a backup return 0 (success) even if the backup fails. - if validation fails: - move tdb to name.corrupt (don't exit if this fails) - look for a valid backup - if a valid backup is found, restore it, else return -1 (failure) if restoring succeeds, return 0 (success), else -1 (failure) Summing up: If 0 is returned, there is a valid tdb at the given location: either the original one ore one restrored from a backup. If -1 is returned, there is no valid tdb at the given location: Either there is no file at all, or the original file is still in place (if moving it away failed). Michael
* r23938: Add a debug message.Michael Adam2007-07-171-0/+2
|
* r23932: Fill extended status with information in case the validation traverseMichael Adam2007-07-171-1/+5
| | | | | | | | functions did not do so but returned an error. (This is the case when error occurred deeper than at the level of the content checking done by the per entry validate_fn.) Michael
* r23930: Introduce tdb_validate_and_backup:Michael Adam2007-07-171-1/+239
| | | | | | | | | | | | | | | | | | This is a wrapper around tdb_validate, that does backup handling: * if the given tdb is valid, a backup is created (name.bak) * if the tdb is invalid, if a valid bakup is found (validated with the same validation function) under the name "name.bak" the orignal tdb is moved to name.corrupt and the backup is restored. For the backup handling, a variant of the backup_tdb function from lib/tdb/tools/tdbbackup.c is included in lib/util_tdb.c. The copy function for the traverse action eliminates the need to maintain a global success state by using a struct wrapping the target tdb and a success flag as the private data. Michael
* r23828: Add entry and exit debug statments to tdb_validateMichael Adam2007-07-111-0/+5
| | | | | | at a lower debug level. Michael
* r23822: Clean some debugging output (as well in content andMichael Adam2007-07-101-34/+19
| | | | | | amount as in source code formatting...) Michael
* r23819: It is currently unnecessary to pass the extended validation statusMichael Adam2007-07-101-42/+10
| | | | | | | | from the validating child process down to the parent though the pipe. All the parent evaluates is the overall success, so the exit status should do. Michael
* r23814: Fix a couple of comments and debug messages.Michael Adam2007-07-101-7/+7
|
* r23784: use the GPLv3 boilerplate as recommended by the FSF and the license textAndrew Tridgell2007-07-101-2/+1
|
* r23780: Find and fix more GPL2 -> GPL3.Jeremy Allison2007-07-091-1/+1
| | | | Jeremy.
* r23769: Move removal of the tdb from the generic tdb_validate functionMichael Adam2007-07-091-6/+0
| | | | | | | to the caller (winbindd_validate_cache in this case). Next, there will be a backup handling for the tdb files. Michael
* r23751: Call tdb_close even when validation was not successful.Michael Adam2007-07-081-9/+1
| | | | Michael
* r23639: Eliminate trailing whitespaces in the new tdb_validate functions...Michael Adam2007-06-271-8/+7
| | | | Michael
* r23610: Move some winbindd_cache specific flags and actions Michael Adam2007-06-261-7/+1
| | | | | | | | back to winbindd_cache.c. The generic mechanism should open the cache tdb readonly and with default flags. Michael
* r23600: First step in abstracting the winbindd cache validation Michael Adam2007-06-251-0/+203
| | | | | | | code into a generic tdb validation code. In lib/util_tdb.c for a start. Michael
* r23511: Merge branches/SAMBA_3_0@23510James Peach2007-06-151-2/+2
| | | | | Tidy calls to smb_panic by removing trailing newlines. Print the failed expression in SMB_ASSERT.
* r23362: Respect "use mmap" in tdb_wrap_open(). Tridge, you might want to mergeVolker Lendecke2007-06-061-0/+3
| | | | this in your tree.
* r23170: Add map_nt_error_from_tdb()Volker Lendecke2007-05-281-0/+37
|
* r22945: merge 22009 from SAMBA_3_0 + some warning fixes for new code:Stefan Metzmacher2007-05-161-15/+15
| | | | | | | | change TDB_DATA from char * to unsigned char * and fix all compiler warnings in the users metze
* r22938: merge 22007 and 22008 from SAMBA_3_0Stefan Metzmacher2007-05-161-2/+2
| | | | | | use tdb helper functions metze
* r22935: merge 21972 from SAMBA_3_0Stefan Metzmacher2007-05-161-22/+39
| | | | metze
* r21960: Fix bugs 4463,4464,4465,4466. Thanks Jason :-)Volker Lendecke2007-03-241-13/+0
|
* r21322: No feedback means consent :-)Volker Lendecke2007-02-131-0/+98
| | | | | | | | | | | It does not matter if I screw up 3.0.25 or 3.0.26 with this, so do it rather sooner than later. Add the notify support that already exists in 3_0 to 3_0_25. If you want to see this patch dissected into digestable parts, look at 3_0, revisions at about 20800 and following. Volker
* r19448: Convert delete_share_security to struct share_params plus some cleanupsVolker Lendecke2006-10-211-0/+29
|
* r19429: moved tdb/common/tdbutil.c into lib/util_tdb.cAndrew Tridgell2006-10-201-0/+811
see discussion on samba-technical