diff --git a/src/perl/ui/Themes.xs b/src/perl/ui/Themes.xs index 568a8f54..f4283f9b 100644 --- a/src/perl/ui/Themes.xs +++ b/src/perl/ui/Themes.xs @@ -6,16 +6,16 @@ void printformat_perl(TEXT_DEST_REC *dest, char *format, char **arglist) char *module, *str; int formatnum; + module = g_strdup(perl_get_package()); formatnum = format_find_tag(module, format); if (formatnum < 0) { die("printformat(): unregistered format '%s'", format); + g_free(module); return; } - module = g_strdup(perl_get_package()); theme = dest->window->theme == NULL ? current_theme : dest->window->theme; - signal_emit("print format", 5, theme, module, &dest, GINT_TO_POINTER(formatnum), arglist);