summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2012-03-07 13:12:19 +0100
committerDaniel Friesel <derf@finalrewind.org>2012-03-07 13:12:19 +0100
commitd0721373fa0a9d189ea95ec736f661cc0df436cd (patch)
tree600dd44a2fc60efe5e1509e63144597afa5f59fe
parent1bd61f53f45da77112313de99de0c8f1fa513bdb (diff)
Fix memory leak in feh_edit_inplace_lossless
-rw-r--r--src/imlib.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/imlib.c b/src/imlib.c
index 1b17b49..c0252c3 100644
--- a/src/imlib.c
+++ b/src/imlib.c
@@ -1108,7 +1108,7 @@ void feh_edit_inplace_lossless(winwidget w, int op)
"-outfile", file_str, file_str, NULL);
im_weprintf(w, "lossless %s: Is 'jpegtran' installed? Failed to exec:", op_name);
- return;
+ exit(1);
} else {
waitpid(pid, &status, 0);
@@ -1118,9 +1118,11 @@ void feh_edit_inplace_lossless(winwidget w, int op)
" Commandline was: "
"jpegtran -copy all %s %s -outfile %s %s",
op_name, status >> 8, op_op, op_value, file_str, file_str);
+ free(file_str);
return;
}
}
+ free(file_str);
}
void feh_draw_actions(winwidget w)