From bce7064cdb7c33731fca29013b17ee2837b9ca4d Mon Sep 17 00:00:00 2001 From: Nikolas Garofil Date: Sun, 21 Nov 2010 14:32:59 +0100 Subject: [PATCH] Bugfix: segfault at config reload --- src/conky.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/conky.cc b/src/conky.cc index 39aafdb9..2ba425fc 100644 --- a/src/conky.cc +++ b/src/conky.cc @@ -2469,6 +2469,8 @@ void initialisation(int argc, char** argv); static void reload_config(void) { clean_up(NULL, NULL); + state.reset(new lua::state); + conky::export_symbols(*state); sleep(1); /* slight pause */ initialisation(argc_copy, argv_copy); } @@ -2583,11 +2585,10 @@ static void set_default_configurations(void) info.xmms2.status = NULL; info.xmms2.playlist = NULL; #endif /* BUILD_XMMS2 */ -#ifdef BUILD_X11 state->pushboolean(true); +#ifdef BUILD_X11 out_to_x.lua_set(*state); #else - state->pushboolean(true); out_to_stdout.lua_set(*state); #endif