mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-12-18 18:04:35 -05:00
Fix minor TOTP issues
* Fix #5105 - prevent divide-by-zero segfault due to invalid TOTP settings * Clear TOTP settings if attributes are removed
This commit is contained in:
parent
747be8d629
commit
d6857e654f
2 changed files with 3 additions and 1 deletions
|
|
@ -481,6 +481,8 @@ void Entry::updateTotp()
|
|||
m_attributes->value(Totp::ATTRIBUTE_SEED));
|
||||
} else if (m_attributes->contains(Totp::ATTRIBUTE_OTP)) {
|
||||
m_data.totpSettings = Totp::parseSettings(m_attributes->value(Totp::ATTRIBUTE_OTP));
|
||||
} else {
|
||||
m_data.totpSettings.reset();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue