summaryrefslogtreecommitdiff
path: root/source4/scripting/libjs
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2007-12-05 03:00:48 +0100
committerStefan Metzmacher <metze@samba.org>2007-12-21 05:48:18 +0100
commitc3c27fadc0a53f8d3de57bae1158a8b244742d72 (patch)
tree6af09fcf0ff97a9acd4bbb1f0f0e47c896875b26 /source4/scripting/libjs
parentd8b91031116b81ae10e2a0fc568ccbf88052e0f3 (diff)
downloadsamba-c3c27fadc0a53f8d3de57bae1158a8b244742d72.tar.gz
samba-c3c27fadc0a53f8d3de57bae1158a8b244742d72.tar.bz2
samba-c3c27fadc0a53f8d3de57bae1158a8b244742d72.zip
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 used to be commit 1fb8c31a3da6fc07f55027f05dba5e03dcf8a4f7)
Diffstat (limited to 'source4/scripting/libjs')
-rw-r--r--source4/scripting/libjs/provision.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/source4/scripting/libjs/provision.js b/source4/scripting/libjs/provision.js
index e7e844bb89..5e9e43a858 100644
--- a/source4/scripting/libjs/provision.js
+++ b/source4/scripting/libjs/provision.js
@@ -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) {