Merge branch 'v4-0-test' of git://git.samba.org/samba into 4-0-local
authorAndrew Bartlett <abartlet@samba.org>
Thu, 10 Jan 2008 22:55:28 +0000 (09:55 +1100)
committerAndrew Bartlett <abartlet@samba.org>
Thu, 10 Jan 2008 22:55:28 +0000 (09:55 +1100)
(This used to be commit 588531bf211f5ede2731df56fd540934b673a2d7)

.gitignore
source4/lib/tdb/python/tdbdump.py [new file with mode: 0644]

index 8af28d01af724792db40ca83d1e58004ee6c8f2f..7d87dbff5314bfd2a600425461808464bcf1bf87 100644 (file)
@@ -7,6 +7,7 @@ autom4te.cache
 *.x
 *.hd
 *.ho
+*.pyc
 Makefile
 configure
 source/bin/*
@@ -179,3 +180,15 @@ source/lib/registry/tools/common.h
 source/librpc/ndr/ndr_table.h
 source/rpc_server/lsa/proto.h
 source/torture/winbind/proto.h
+*~
+source/auth/auth_sam_reply.h
+source/auth/session_proto.h
+source/auth/system_session_proto.h
+source/dsdb/common/proto.h
+source/dsdb/schema/proto.h
+source/lib/crypto/test_proto.h
+source/lib/registry/tests/proto.h
+source/lib/util/apidocs
+source/lib/util/util_ldb.h
+source/libcli/ldap/ldap_ndr.h
+source/libcli/resolve/lp_proto.h
diff --git a/source4/lib/tdb/python/tdbdump.py b/source4/lib/tdb/python/tdbdump.py
new file mode 100644 (file)
index 0000000..d759d77
--- /dev/null
@@ -0,0 +1,12 @@
+#!/usr/bin/python
+# Trivial reimplementation of tdbdump in Python
+
+import tdb, sys
+
+if len(sys.argv) < 2:
+    print "Usage: tdbdump.py <tdb-file>"
+    sys.exit(1)
+
+db = tdb.Tdb(sys.argv[1])
+for (k, v) in db.iteritems():
+    print "{\nkey(%d) = %r\ndata(%d) = %r\n}" % (len(k), k, len(v), v)