commit 98731f9d70344116ce382d9b866cacf31cf02aaf
parent 3530d881e3d9b28725ca4657d57da972237f0f18
Author: Michael Rasmussen <mir@datanom.net>
Date: Thu, 9 Sep 2021 23:51:32 +0200
Fix CID 1491376
Signed-off-by: Michael Rasmussen <mir@datanom.net>
Diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/procmime.c b/src/procmime.c
@@ -723,7 +723,8 @@ gint procmime_get_part(const gchar *outfile, MimeInfo *mimeinfo)
if (claws_fclose(outfp) == EOF) {
saved_errno = errno;
FILE_OP_ERROR(outfile, "claws_fclose");
- claws_unlink(outfile);
+ if (claws_unlink(outfile) < 0)
+ FILE_OP_ERROR(outfile, "claws_unlink");
return -(saved_errno);
}