From: Ivan Rako Date: Thu, 8 Dec 2011 16:09:10 +0000 (+0100) Subject: izmjene unutar cp_get_ldap_realm X-Git-Tag: debian/3.0.1~7 X-Git-Url: http://ftp.carnet.hr/carnet-debian/scm?a=commitdiff_plain;h=c36c7532f58f6554cce86a585ed83e92784699ff;p=carnet-upgrade.git izmjene unutar cp_get_ldap_realm --- diff --git a/debian/changelog b/debian/changelog index 8d32522..c7461f8 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +carnet-tools-cn (3.0.3) stable; urgency=low + + * Izmjene unutar cp_get_ldap_realm + + -- Ivan Rako Thu, 08 Dec 2011 17:08:59 +0100 + carnet-tools-cn (3.0.2) stable; urgency=low * cp_get_ldap_suffix cita iz /etc/ldap/slapd.d, ako on ne postoji, cita diff --git a/functions.sh b/functions.sh index d63d500..9b549f5 100644 --- a/functions.sh +++ b/functions.sh @@ -487,8 +487,11 @@ cp_get_ldap_realm() { # but preserving initial state so it could be used afterwards CP_ECHO_RETURN="" - if [ ! -f /etc/ldap/slapd.d/ ]; then - echo "cp_get_ldap_realm: /etc/ldap/slapd.d/: No such directory" >&2 + if [ ! -d /etc/ldap/slapd.d/ ]; then + echo "cp_get_ldap_suffix: /etc/ldap/slapd.d/: No such directory" >&2 + return 2 + elif [ ! -f /etc/ldap/slapd.conf ]; then + echo "cp_get_ldap_suffix: /etc/ldap/slapd.conf: No such file" >&2 return 2 fi