[nemiver] Fix a crash in previous commit
- From: Dodji Seketeli <dodji src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nemiver] Fix a crash in previous commit
- Date: Mon, 4 Apr 2011 15:01:17 +0000 (UTC)
commit ceb8590aae4d9bb6beeb2e8a7357d37ad2a16ac6
Author: Dodji Seketeli <dodji seketeli org>
Date: Mon Apr 4 16:50:39 2011 +0200
Fix a crash in previous commit
* src/confmgr/nmv-gsettings-mgr.cc
(GSettingsMgr::register_namespace): Bind the namespace name
to the parameter of the signal handler by value; not by
reference. This avoids a crash when the signal slots later try to
poke at the namespace parameter.
(GSettingsMgr::set_key_value): Fix thinko.
src/confmgr/nmv-gsettings-mgr.cc | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/confmgr/nmv-gsettings-mgr.cc b/src/confmgr/nmv-gsettings-mgr.cc
index ca664c4..83d242a 100644
--- a/src/confmgr/nmv-gsettings-mgr.cc
+++ b/src/confmgr/nmv-gsettings-mgr.cc
@@ -123,7 +123,7 @@ GSettingsMgr::register_namespace (const UString &a_name)
Gio::Settings::create (name);
THROW_IF_FAIL (settings);
- settings->signal_changed ().connect (sigc::bind<const UString&> (
+ settings->signal_changed ().connect (sigc::bind<const UString> (
sigc::mem_fun (m_value_changed_signal,
&sigc::signal<void,
const UString&,
@@ -220,7 +220,7 @@ GSettingsMgr::set_key_value (const UString &a_key,
UString ns = a_namespace;
ENSURE_NAMESPACE_NOT_EMPTY (ns);
- Glib::RefPtr<Gio::Settings> settings = m_settings[a_namespace];
+ Glib::RefPtr<Gio::Settings> settings = m_settings[ns];
THROW_IF_FAIL (settings);
settings->set_int (a_key, a_value);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]