1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-11 05:18:09 +03:00

r26303: Fix up error reporting during the delete of previous entries in the

provision, and ignore 'no such entry' as an error (it is normal, and
just means the partition is compleatly empty).

Andrew Bartlett
This commit is contained in:
Andrew Bartlett 2007-12-05 03:00:48 +01:00 committed by Stefan Metzmacher
parent a7595d009a
commit 1fb8c31a3d

View File

@ -224,7 +224,10 @@ function ldb_erase_partitions(info, ldb, ldapbackend)
var res2 = ldb.search(anything, basedn, ldb.SCOPE_SUBTREE, attrs);
var i;
if (res2.error != 0) {
info.message("ldb search failed: " + res.errstr + "\n");
if (res2.error == 32) {
break;
}
info.message("ldb search failed: " + res2.errstr + "\n");
continue;
}
previous_remaining = current_remaining;
@ -235,7 +238,7 @@ function ldb_erase_partitions(info, ldb, ldapbackend)
var res3 = ldb.search(anything, basedn, ldb.SCOPE_SUBTREE, attrs);
if (res3.error != 0) {
info.message("ldb search failed: " + res.errstr + "\n");
info.message("ldb search failed: " + res3.errstr + "\n");
continue;
}
if (res3.msgs.length != 0) {