mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Always handle NotFound error in dnsrecord-mod
When there were no updated attrs when modifying a nonexistent DNS record, the error was not handled and caused an internal server error later (old_entry was used uninitialized). https://fedorahosted.org/freeipa/ticket/3055
This commit is contained in:
committed by
Martin Kosek
parent
230261a1a5
commit
0b254e8b1e
@@ -2455,8 +2455,7 @@ class dnsrecord_mod(LDAPUpdate):
|
||||
(dn_, old_entry) = ldap.get_entry(dn, _record_attributes,
|
||||
normalize=self.obj.normalize_dn)
|
||||
except errors.NotFound:
|
||||
if updated_attrs:
|
||||
self.obj.handle_not_found(*keys)
|
||||
self.obj.handle_not_found(*keys)
|
||||
|
||||
if updated_attrs:
|
||||
for attr in updated_attrs:
|
||||
|
||||
Reference in New Issue
Block a user