summaryrefslogtreecommitdiffstats
path: root/src/utils/padsp.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils/padsp.c')
-rw-r--r--src/utils/padsp.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/utils/padsp.c b/src/utils/padsp.c
index dfa5aac2..882522c4 100644
--- a/src/utils/padsp.c
+++ b/src/utils/padsp.c
@@ -53,6 +53,7 @@
#include <pulse/pulseaudio.h>
#include <pulse/gccmacro.h>
#include <pulsecore/llist.h>
+#include <pulsecore/core-util.h>
/* On some systems SIOCINQ isn't defined, but FIONREAD is just an alias */
#if !defined(SIOCINQ) && defined(FIONREAD)
@@ -459,15 +460,16 @@ static void reset_params(fd_info *i) {
}
static const char *client_name(char *buf, size_t n) {
- char p[PATH_MAX];
+ char *p;
const char *e;
if ((e = getenv("PADSP_CLIENT_NAME")))
return e;
- if (pa_get_binary_name(p, sizeof(p)))
+ if ((p = pa_get_binary_name_malloc())) {
snprintf(buf, n, "OSS Emulation[%s]", p);
- else
+ pa_xfree(p);
+ } else
snprintf(buf, n, "OSS");
return buf;