]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
make sure that zone2ldap encodes root as .
authorbert hubert <bert.hubert@powerdns.com>
Wed, 7 Sep 2016 19:21:53 +0000 (21:21 +0200)
committerbert hubert <bert.hubert@powerdns.com>
Tue, 13 Sep 2016 10:53:30 +0000 (12:53 +0200)
pdns/zone2ldap.cc

index bbb65f2fee211f87cb95f11bdfd114b76d8109a6..e17d2f2a63ad2c9c5ca77eb1233ef65fb36f3154 100644 (file)
@@ -83,8 +83,8 @@ static void callback_simple( unsigned int domain_id, const DNSName &domain, cons
                 cout << "changetype: modify" << endl;
                 cout << "add: " << qtype << "Record" << endl;
         }
-
-        cout << qtype << "Record: " << stripDot( content ) << endl << endl;
+        string stripped=stripDot(content);
+        cout << qtype << "Record: " << stripped << ((stripped.empty() || stripped[stripped.size()-1]==' ') ? "." : "") << endl << endl;
 }