diff options
author | Daniel Mack <github@zonque.org> | 2015-09-09 15:45:03 +0200 |
---|---|---|
committer | Daniel Mack <github@zonque.org> | 2015-09-09 15:45:03 +0200 |
commit | 01da201420edfb2a57e384f109def05f25429305 (patch) | |
tree | 1c3090f3b5200ba62613285553afa0f7a6d30b9a /src/core/mount.c | |
parent | 37b76fd3ee5a03d76786e7bd1e0f8596e6ce47d6 (diff) | |
parent | 74ca738f6a01fb5fc19c5c3899f5cb1fdc1d7f68 (diff) |
Merge pull request #1218 from poettering/safe-fclose
util: introduce safe_fclose() and port everything over to it
Diffstat (limited to 'src/core/mount.c')
-rw-r--r-- | src/core/mount.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/core/mount.c b/src/core/mount.c index 83746ca412..1f02aa5566 100644 --- a/src/core/mount.c +++ b/src/core/mount.c @@ -1540,10 +1540,7 @@ static void mount_shutdown(Manager *m) { m->mount_event_source = sd_event_source_unref(m->mount_event_source); m->mount_utab_event_source = sd_event_source_unref(m->mount_utab_event_source); - if (m->proc_self_mountinfo) { - fclose(m->proc_self_mountinfo); - m->proc_self_mountinfo = NULL; - } + m->proc_self_mountinfo = safe_fclose(m->proc_self_mountinfo); m->utab_inotify_fd = safe_close(m->utab_inotify_fd); } |