svn commit: samba r12703 - in branches/SAMBA_4_0/source/scripting/libjs: .

jelmer at samba.org jelmer at samba.org
Tue Jan 3 20:26:58 GMT 2006


Author: jelmer
Date: 2006-01-03 20:26:57 +0000 (Tue, 03 Jan 2006)
New Revision: 12703

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=12703

Log:
Fix handling of short passdb backends (also reported by Steinar Gunderson)

Modified:
   branches/SAMBA_4_0/source/scripting/libjs/upgrade.js


Changeset:
Modified: branches/SAMBA_4_0/source/scripting/libjs/upgrade.js
===================================================================
--- branches/SAMBA_4_0/source/scripting/libjs/upgrade.js	2006-01-03 20:19:39 UTC (rev 12702)
+++ branches/SAMBA_4_0/source/scripting/libjs/upgrade.js	2006-01-03 20:26:57 UTC (rev 12703)
@@ -605,8 +605,10 @@
 	var pdb = samba3.configuration.get_list("passdb backend");
 	if (pdb != undefined) {
 		for (var b in pdb) {
-			if (substr(pdb[b], 0, 7) == "ldapsam") {
-				ldapurl = substr(pdb[b], 8);
+			if (strlen(pdb[b]) >= 7) {
+				if (substr(pdb[b], 0, 7) == "ldapsam") {
+					ldapurl = substr(pdb[b], 8);
+				}
 			}
 		}
 	}



More information about the samba-cvs mailing list