From a7262a0241896a6abadb4104e2fa73325955f8ff Mon Sep 17 00:00:00 2001 From: cajus Date: Fri, 29 Feb 2008 21:05:23 +0000 Subject: [PATCH] Fixed potential empty ridbase git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9222 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-plugins/samba/personal/samba/class_sambaAccount.inc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/gosa-plugins/samba/personal/samba/class_sambaAccount.inc b/gosa-plugins/samba/personal/samba/class_sambaAccount.inc index 06bacdb79..b338fa811 100644 --- a/gosa-plugins/samba/personal/samba/class_sambaAccount.inc +++ b/gosa-plugins/samba/personal/samba/class_sambaAccount.inc @@ -137,7 +137,11 @@ class sambaAccount extends plugin $ldap->search ("(&(objectClass=sambaDomain)(sambaSID=$this->SID))",array("sambaAlgorithmicRidBase","sambaDomainName")); if ($ldap->count() != 0){ $attrs= $ldap->fetch(); - $this->ridBase= $attrs['sambaAlgorithmicRidBase'][0]; + if(isset($attrs['sambaAlgorithmicRidBase'])){ + $this->ridBase= $attrs['sambaAlgorithmicRidBase'][0]; + } else { + $this->ridBase= $this->config->current['RIDBASE']; + } if ($this->sambaDomainName == ""){ $this->sambaDomainName= $attrs['sambaDomainName'][0]; } -- 2.30.2