summaryrefslogtreecommitdiff
path: root/src/shared/sleep-config.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-02-13 14:59:56 +0100
committerLennart Poettering <lennart@poettering.net>2014-02-13 14:59:56 +0100
commitc8a202b7d47f9d6bba3100a208abdadfc383499e (patch)
treed19560cf0723f8e2305170881eb442b5ecb12b0d /src/shared/sleep-config.c
parent955d98c9c1104d469c2989dbfb58f58ee6fe9bdc (diff)
everywhere: always use O_CLOEXEC where it makes sense
Diffstat (limited to 'src/shared/sleep-config.c')
-rw-r--r--src/shared/sleep-config.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shared/sleep-config.c b/src/shared/sleep-config.c
index 70a0896069..b9b6643066 100644
--- a/src/shared/sleep-config.c
+++ b/src/shared/sleep-config.c
@@ -174,7 +174,7 @@ static int hibernation_partition_size(size_t *size, size_t *used) {
assert(size);
assert(used);
- f = fopen("/proc/swaps", "r");
+ f = fopen("/proc/swaps", "re");
if (!f) {
log_full(errno == ENOENT ? LOG_DEBUG : LOG_WARNING,
"Failed to retrieve open /proc/swaps: %m");