summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-07-11 14:19:36 -0300
committerLennart Poettering <lennart@poettering.net>2015-07-11 14:19:36 -0300
commit64ee7ab46211307cea338f35694c802f7abc313f (patch)
treeb3ee0dc5b88efa4a3d5ab25c0951f31486b3e88b /src
parent43694a8cc70667498f3ffc5d9325b7d0428558e5 (diff)
util: make sure we don't clobber errno in error path
Diffstat (limited to 'src')
-rw-r--r--src/basic/util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/basic/util.c b/src/basic/util.c
index c88cd1d38a..13a67e9ab8 100644
--- a/src/basic/util.c
+++ b/src/basic/util.c
@@ -2533,7 +2533,7 @@ int fopen_temporary(const char *path, FILE **_f, char **_temp_path) {
f = fdopen(fd, "we");
if (!f) {
- unlink(t);
+ unlink_noerrno(t);
free(t);
safe_close(fd);
return -errno;