diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-08-17 02:49:53 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-08-17 02:49:53 +0200 |
commit | f12681b09b381e6a61926c3af2b81842b6f0396d (patch) | |
tree | 46dd4c1ed33f0ae544d04b52ed4d2edec2fbad46 /src/config.c | |
parent | 1ebbf81c00fd1f1bd4941bf18a3b3990a77648d2 (diff) | |
download | fastd-f12681b09b381e6a61926c3af2b81842b6f0396d.tar fastd-f12681b09b381e6a61926c3af2b81842b6f0396d.zip |
Check closedir return value
Just for the sake of completeness.
Diffstat (limited to 'src/config.c')
-rw-r--r-- | src/config.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/config.c b/src/config.c index 672c0a7..3c58cd0 100644 --- a/src/config.c +++ b/src/config.c @@ -361,7 +361,9 @@ static void read_peer_dir(fastd_context_t *ctx, fastd_config_t *conf, const char } } - closedir(dirh); + if (closedir(dirh) < 0) + pr_error_errno(ctx, "closedir"); + } else { pr_error(ctx, "opendir for `%s' failed: %s", dir, strerror(errno)); |