summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2019-08-09 14:13:17 +0100
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2019-08-09 14:13:17 +0100
commit758894bc9cd9f0d0332d5c8bd391b80adf8f62ef (patch)
treeba93c553ce34632d2eed58bf4bde1453bbf01759 /src/modules
parent2158d46dbaeb89ce792f102cc861abb378a65b28 (diff)
tiling config -fix use after free crash on change of config
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/tiling/e_mod_config.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/modules/tiling/e_mod_config.c b/src/modules/tiling/e_mod_config.c
index e3ae764..ab1ecfc 100644
--- a/src/modules/tiling/e_mod_config.c
+++ b/src/modules/tiling/e_mod_config.c
@@ -228,7 +228,7 @@ _basic_apply_data(E_Config_Dialog *cfd EINA_UNUSED,
228 E_Config_Dialog_Data *cfdata) 228 E_Config_Dialog_Data *cfdata)
229{ 229{
230 struct _Config_vdesk *vd; 230 struct _Config_vdesk *vd;
231 Eina_List *l; 231 Eina_List *l, *vdesks;
232 232
233 tiling_g.config->tile_dialogs = cfdata->config.tile_dialogs; 233 tiling_g.config->tile_dialogs = cfdata->config.tile_dialogs;
234 tiling_g.config->show_titles = cfdata->config.show_titles; 234 tiling_g.config->show_titles = cfdata->config.show_titles;
@@ -265,10 +265,7 @@ _basic_apply_data(E_Config_Dialog *cfd EINA_UNUSED,
265 } 265 }
266 } 266 }
267 267
268 EINA_LIST_FREE(tiling_g.config->vdesks, vd) 268 vdesks = tiling_g.config->vdesks;
269 {
270 free(vd);
271 }
272 tiling_g.config->vdesks = NULL; 269 tiling_g.config->vdesks = NULL;
273 270
274 for (l = cfdata->config.vdesks; l; l = l->next) 271 for (l = cfdata->config.vdesks; l; l = l->next)
@@ -291,6 +288,11 @@ _basic_apply_data(E_Config_Dialog *cfd EINA_UNUSED,
291 288
292 e_tiling_update_conf(); 289 e_tiling_update_conf();
293 290
291 EINA_LIST_FREE(vdesks, vd)
292 {
293 free(vd);
294 }
295
294 e_config_save_queue(); 296 e_config_save_queue();
295 297
296 return EINA_TRUE; 298 return EINA_TRUE;