]> git.ipfire.org Git - thirdparty/plymouth.git/commitdiff
[script] Free the main script after freeing the state
authorCharlie Brej <cbrej@cs.man.ac.uk>
Mon, 22 Jun 2009 15:42:02 +0000 (16:42 +0100)
committerCharlie Brej <cbrej@cs.man.ac.uk>
Mon, 22 Jun 2009 15:42:02 +0000 (16:42 +0100)
There are links from the script state to parsed script data. Destroy the parsed
data after freeing the state.

This should be done properly with more ref counting or moving the freeme var to
the linking structure.

src/plugins/splash/script/plugin.c

index b3f922ccad46f9c78b843478753df91f92519703..f24511d720f5d660e5a8a4c643dde2127111a712 100644 (file)
@@ -235,11 +235,11 @@ stop_animation (ply_boot_splash_plugin_t *plugin)
                                                 on_timeout, plugin);
     }
  script_state_destroy(plugin->script_state);
- script_parse_op_free (plugin->script_main_op);
  script_lib_sprite_destroy(plugin->script_sprite_lib);
  script_lib_image_destroy(plugin->script_image_lib);
  script_lib_plymouth_destroy(plugin->script_plymouth_lib);
  script_lib_math_destroy(plugin->script_math_lib);
+ script_parse_op_free (plugin->script_main_op);
 }
 
 static void