summaryrefslogtreecommitdiff
path: root/examples/misc
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2007-07-11 09:49:10 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:28:31 -0500
commit47d2f021c80a7d961a211d7b2f8dc899b2f8deca (patch)
tree87afe95db73b1eb7c76677fd084985bf613d1424 /examples/misc
parent1c957f9559880712acd335c9df11191df0386df0 (diff)
downloadsamba-47d2f021c80a7d961a211d7b2f8dc899b2f8deca.tar.gz
samba-47d2f021c80a7d961a211d7b2f8dc899b2f8deca.tar.bz2
samba-47d2f021c80a7d961a211d7b2f8dc899b2f8deca.zip
r23827: Fix schema dump.
Guenther (This used to be commit e3d6dabcb9786ae81f2736815a3b576a962eef3b)
Diffstat (limited to 'examples/misc')
-rwxr-xr-xexamples/misc/adssearch.pl11
1 files changed, 6 insertions, 5 deletions
diff --git a/examples/misc/adssearch.pl b/examples/misc/adssearch.pl
index b880366c88..a63ae311eb 100755
--- a/examples/misc/adssearch.pl
+++ b/examples/misc/adssearch.pl
@@ -837,7 +837,8 @@ sub get_base_from_rootdse {
my $server = shift || "";
$dse = shift || get_dse($server,$async_ldap_hd) || return -1;
- return $dse->get_value('defaultNamingContext');
+ return $dse->get_value($opt_dump_schema ? 'schemaNamingContext':
+ 'defaultNamingContext');
}
sub get_realm_from_rootdse {
@@ -1499,7 +1500,7 @@ sub gen_controls {
critical => 'true',
value => "");
- if (defined($opt_paging)) {
+ if (defined($opt_paging) || $opt_dump_schema) {
push(@ctrls, $ctl_paged);
push(@ctrls_s, "LDAP_PAGED_RESULT_OID_STRING" );
}
@@ -1787,9 +1788,9 @@ sub main () {
if ($opt_dump_schema) {
print "Dumping Schema:\n";
- my $ads_schema = $async_ldap_hd->schema;
- $ads_schema->dump;
- exit 0;
+# my $ads_schema = $async_ldap_hd->schema;
+# $ads_schema->dump;
+# exit 0;
}
while (1) {