X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/670f9935630beb2123a5ca62894ae92a3f0efa4f..f5766910b6731eb03e82371416e9778203396ce7:/src/msw/regconf.cpp?ds=sidebyside diff --git a/src/msw/regconf.cpp b/src/msw/regconf.cpp index 4c9d9e5fb7..1777569b88 100644 --- a/src/msw/regconf.cpp +++ b/src/msw/regconf.cpp @@ -699,7 +699,18 @@ bool wxRegConfig::DeleteGroup(const wxString& key) { wxConfigPathChanger path(this, key); - return m_keyLocal.Exists() ? LocalKey().DeleteKey(path.Name()) : true; + if ( !m_keyLocal.Exists() ) + { + // nothing to do + return true; + } + + if ( !LocalKey().DeleteKey(path.Name()) ) + return false; + + path.UpdateIfDeleted(); + + return true; } bool wxRegConfig::DeleteAll() @@ -717,5 +728,4 @@ bool wxRegConfig::DeleteAll() return bOk; } -#endif - // wxUSE_CONFIG +#endif // wxUSE_CONFIG