diff options
author | Pierre Ossman <ossman@cendio.se> | 2007-02-05 10:26:14 +0000 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2007-02-05 10:26:14 +0000 |
commit | f65ab1b3eb2cd91f0bb98f18517e48156177e679 (patch) | |
tree | 4047c9ae5c45b7d69a3f22442215fe4a4e789f48 /src/pulsecore | |
parent | 4171f2504a4e0de5c46c3237da009f5355cf57ec (diff) |
Don't abort config loading when the user specific cannot be loaded.
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@1423 fefdeb5f-60dc-0310-8127-8f9354f1896f
Diffstat (limited to 'src/pulsecore')
-rw-r--r-- | src/pulsecore/core-util.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/pulsecore/core-util.c b/src/pulsecore/core-util.c index b42dc0ca..1e8fd23b 100644 --- a/src/pulsecore/core-util.c +++ b/src/pulsecore/core-util.c @@ -184,7 +184,7 @@ int pa_make_secure_dir(const char* dir, mode_t m, uid_t uid, gid_t gid) { goto fail; } #else - pa_log_warn("secure directory creation not supported on Win32."); + pa_log_warn("secure directory creation not supported on Win32."); #endif return 0; @@ -953,13 +953,19 @@ FILE *pa_open_config_file(const char *global, const char *local, const char *env fn = buf; #endif - if ((f = fopen(fn, mode)) || errno != ENOENT) { + f = fopen(fn, mode); + if (f != NULL) { if (result) *result = pa_xstrdup(fn); pa_xfree(lfn); return f; } + if (errno != ENOENT) { + pa_log_warn("WARNING: failed to open configuration file '%s': %s", + lfn, pa_cstrerror(errno)); + } + pa_xfree(lfn); } } |