summaryrefslogtreecommitdiffstats
path: root/src/pulsecore/core-util.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2009-02-20 03:21:46 +0100
committerLennart Poettering <lennart@poettering.net>2009-02-20 03:21:46 +0100
commit7bc1847596bdedea6a06c8c0a019da773476a965 (patch)
tree521be5207d649ff24f022c9bfe31a716a2674317 /src/pulsecore/core-util.c
parent26a270a934f0f174f7bd7eb89e85301963721deb (diff)
parent2e250aaebb7708b25b5342d8ced657364adedc95 (diff)
Merge branch 'master' of ssh://rootserver/home/lennart/git/public/pulseaudio
Diffstat (limited to 'src/pulsecore/core-util.c')
-rw-r--r--src/pulsecore/core-util.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/pulsecore/core-util.c b/src/pulsecore/core-util.c
index 61f9a656..a184bebd 100644
--- a/src/pulsecore/core-util.c
+++ b/src/pulsecore/core-util.c
@@ -1411,6 +1411,7 @@ static int make_random_dir_and_link(mode_t m, const char *k) {
return -1;
}
+ pa_xfree(p);
return 0;
}
@@ -1443,6 +1444,7 @@ char *pa_get_runtime_dir(void) {
if (pa_make_secure_dir(d, m, (uid_t) -1, (gid_t) -1) < 0) {
pa_log_error("Failed to create secure directory: %s", pa_cstrerror(errno));
+ pa_xfree(d);
goto fail;
}
@@ -2459,7 +2461,7 @@ char *pa_machine_id(void) {
pa_strip_nl(ln);
- if (ln[0])
+ if (r && ln[0])
return pa_xstrdup(ln);
}