summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/imlib.c1
-rw-r--r--src/winwidget.c1
2 files changed, 2 insertions, 0 deletions
diff --git a/src/imlib.c b/src/imlib.c
index 9aa166f..4f7ff24 100644
--- a/src/imlib.c
+++ b/src/imlib.c
@@ -305,6 +305,7 @@ static char *feh_magick_load_image(char *filename)
if (!WIFEXITED(status) || (WEXITSTATUS(status) != 0)) {
close(fd);
unlink(sfn);
+ free(sfn);
sfn = NULL;
if (!opt.quiet) {
diff --git a/src/winwidget.c b/src/winwidget.c
index ae34045..0a9adc8 100644
--- a/src/winwidget.c
+++ b/src/winwidget.c
@@ -42,6 +42,7 @@ static winwidget winwidget_allocate(void)
winwidget ret = NULL;
ret = emalloc(sizeof(_winwidget));
+ memset(ret, 0, sizeof(_winwidget));
ret->win = 0;
ret->w = 0;