]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
samba-tool: let 'samba-tool user syncpasswords' report deletions immediately
authorStefan Metzmacher <metze@samba.org>
Tue, 25 Apr 2017 11:25:57 +0000 (13:25 +0200)
committerKarolin Seeger <kseeger@samba.org>
Tue, 9 May 2017 12:34:10 +0000 (14:34 +0200)
We need to use the show-recycled control in addition to the
notification control in order to get notifications about deletions.

There's no real problem as the next modification will report the deletion.
But it might be delayed a few minutes.

Note that show-recycled is a superset of show-deleted, so we only need one.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12767

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
(cherry picked from commit afa15e6128473d3e4006f7cdc3762ab4c1cba05a)

Autobuild-User(v4-5-test): Karolin Seeger <kseeger@samba.org>
Autobuild-Date(v4-5-test): Tue May  9 14:34:10 CEST 2017 on sn-devel-144

python/samba/netcmd/user.py

index 2cceea8a7d0a8b57f860d945ccc850d2f3e8b9e2..4f1bce8ab31eea4f8a396dba253f91aae5da4178 100644 (file)
@@ -1848,7 +1848,7 @@ samba-tool user syncpasswords --terminate \\
 
         def sync_loop(wait):
             notify_attrs = ["name", "uSNCreated", "uSNChanged", "objectClass"]
-            notify_controls = ["notification:1"]
+            notify_controls = ["notification:1", "show_recycled:1"]
             notify_handle = self.samdb.search_iterator(expression="objectClass=*",
                                                        scope=ldb.SCOPE_SUBTREE,
                                                        attrs=notify_attrs,