Mailinglist Archive: yast-commit (2113 mails)

< Previous Next >
[yast-commit] r58848 - in /trunk/ldap-server/src: LdapDatabase.ycp agent/SlapdConfigAgent.cc
  • From: rhafer@xxxxxxxxxxxxxxxx
  • Date: Wed, 30 Sep 2009 15:38:45 -0000
  • Message-id: <E1Mt1GP-0006gO-By@xxxxxxxxxxxxxxxx>
Author: rhafer
Date: Wed Sep 30 17:38:45 2009
New Revision: 58848

URL: http://svn.opensuse.org/viewcvs/yast?rev=58848&view=rev
Log:
Workaround empty suffix from configdb

Modified:
trunk/ldap-server/src/LdapDatabase.ycp
trunk/ldap-server/src/agent/SlapdConfigAgent.cc

Modified: trunk/ldap-server/src/LdapDatabase.ycp
URL:
http://svn.opensuse.org/viewcvs/yast/trunk/ldap-server/src/LdapDatabase.ycp?rev=58848&r1=58847&r2=58848&view=diff
==============================================================================
--- trunk/ldap-server/src/LdapDatabase.ycp (original)
+++ trunk/ldap-server/src/LdapDatabase.ycp Wed Sep 30 17:38:45 2009
@@ -1298,11 +1298,12 @@
global boolean DbAclInput( symbol handler_cmd, integer dbindex )
{
map db = $[];
- if ( dbindex > 0 )
+ if ( dbindex >= 0 )
{
db = LdapServer::ReadDatabase(dbindex);
}
string suffix = db["suffix"]:"";
+ y2milestone("suffix: %1", suffix);
boolean updateTable = false;

integer selected = (integer)UI::QueryWidget( `id( `tab_acl ),
`CurrentItem );

Modified: trunk/ldap-server/src/agent/SlapdConfigAgent.cc
URL:
http://svn.opensuse.org/viewcvs/yast/trunk/ldap-server/src/agent/SlapdConfigAgent.cc?rev=58848&r1=58847&r2=58848&view=diff
==============================================================================
--- trunk/ldap-server/src/agent/SlapdConfigAgent.cc (original)
+++ trunk/ldap-server/src/agent/SlapdConfigAgent.cc Wed Sep 30 17:38:45 2009
@@ -544,10 +544,15 @@
if ( path->length() == 1 )
{
std::string dbtype = (*i)->getType();
+ std::string suffix = (*i)->getStringValue("olcSuffix");
+ y2milestone("suffix %s, dbtype %s\n", suffix.c_str(),
dbtype.c_str() );
+ if ( suffix.empty() && dbtype == "config" )
+ {
+ suffix = "cn=config";
+ }
+ resMap.add( YCPString("suffix"), YCPString(suffix) );
resMap.add( YCPString( "type" ),
YCPString( dbtype ) );
- resMap.add( YCPString("suffix"),
- YCPString( (*i)->getStringValue("olcSuffix") ));
resMap.add( YCPString("rootdn"),
YCPString( (*i)->getStringValue("olcRootDn") ));
resMap.add( YCPString("rootpw"),

--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages