From: Jennifer Sutton Date: Mon, 2 Sep 2024 23:38:44 +0000 (+1200) Subject: python: Make set of seen GUIDs a local variable X-Git-Tag: tevent-0.17.0~134 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=44548de57a3f2932bb6546945cdb6f2212d3c4c2;p=thirdparty%2Fsamba.git python: Make set of seen GUIDs a local variable BUG: https://bugzilla.samba.org/show_bug.cgi?id=15852 Signed-off-by: Jennifer Sutton Reviewed-by: Douglas Bagnall --- diff --git a/python/samba/drs_utils.py b/python/samba/drs_utils.py index 3907743b62e..4b7fdacd846 100644 --- a/python/samba/drs_utils.py +++ b/python/samba/drs_utils.py @@ -224,7 +224,7 @@ class drs_Replicate(object): def _calculate_missing_anc_locally(self, ctr): - self.guids_seen = set() + guids_seen = set() # walk objects in ctr, add to guids_seen as we see them # note if an object doesn't have a parent @@ -232,12 +232,12 @@ class drs_Replicate(object): object_to_check = ctr.first_object while object_to_check is not None: - self.guids_seen.add(str(object_to_check.object.identifier.guid)) + guids_seen.add(str(object_to_check.object.identifier.guid)) if object_to_check.parent_object_guid is not None \ and object_to_check.parent_object_guid \ != misc.GUID("00000000-0000-0000-0000-000000000000") \ - and str(object_to_check.parent_object_guid) not in self.guids_seen: + and str(object_to_check.parent_object_guid) not in guids_seen: obj_dn = ldb.Dn(self.samdb, object_to_check.object.identifier.dn) parent_dn = obj_dn.parent() print(f"Object {parent_dn} with "