]> git.ipfire.org Git - thirdparty/samba.git/commit
python:netcmd:gpo: fix crash when updating an MOTD GPO
authorAndreas Hasenack <andreas.hasenack@canonical.com>
Tue, 18 Feb 2025 15:43:46 +0000 (12:43 -0300)
committerJule Anger <janger@samba.org>
Thu, 17 Apr 2025 11:31:14 +0000 (11:31 +0000)
commit7f76df8a6f02497c3f04622c694f9e2761a84797
treebc0c6d2c97910be07b557f2e58c14d8ba9da7b62
parentf252b2b42d86c3e539b0f9942ccfddffebd0bdef
python:netcmd:gpo: fix crash when updating an MOTD GPO

When the policy exists already, there is no exception and the code
tries to use the "data" variable, but it doesn't exist because it was
only defined in the exception handling.

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

Signed-off-by: Andreas Hasenack <andreas.hasenack@canonical.com>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Jennifer Sutton <jennifersutton@catalyst.net.nz>
(cherry picked from commit e87e20c04d90292e3a5caac8ea3105b16f948ed3)
python/samba/netcmd/gpo.py
selftest/knownfail.d/samba-tool-gpo [deleted file]