]> git.pld-linux.org Git - packages/pulseaudio.git/blame - pulseaudio-pa-machine-id.patch
- release 3 (by relup.sh)
[packages/pulseaudio.git] / pulseaudio-pa-machine-id.patch
CommitLineData
00d6c138
JB
1--- pulseaudio-4.0/configure.ac.orig 2013-06-08 13:07:47.119786074 +0200
2+++ pulseaudio-4.0/configure.ac 2013-06-08 13:09:53.796450100 +0200
3@@ -991,6 +991,8 @@
34291079 4
00d6c138
JB
5 PA_MACHINE_ID="${sysconfdir}/machine-id"
6 AX_DEFINE_DIR(PA_MACHINE_ID, PA_MACHINE_ID, [D-Bus machine-id file])
cb7f049c 7+PA_PA_MACHINE_ID="${sysconfdir}/pulse/machine-id"
34291079 8+AX_DEFINE_DIR(PA_PA_MACHINE_ID, PA_PA_MACHINE_ID, [PA machine-id file])
00d6c138
JB
9 PA_MACHINE_ID_FALLBACK="${localstatedir}/lib/dbus/machine-id"
10 AX_DEFINE_DIR(PA_MACHINE_ID_FALLBACK, PA_MACHINE_ID_FALLBACK,
11 [Fallback machine-id file])
f105a6c8
JP
12--- pulseaudio-8.0/src/pulsecore/core-util.c.orig 2016-01-22 19:14:53.600528288 +0100
13+++ pulseaudio-8.0/src/pulsecore/core-util.c 2016-01-22 19:19:09.026774778 +0100
14@@ -3066,6 +3066,20 @@
15 * identifier that suits our needs perfectly. If it's not, we fall back to
16 * the hostname, which is not as good, since it can change over time. */
cf87a08b
JR
17
18+ /* First we try locally configured ID */
19+
cb7f049c 20+ if ((f = pa_fopen_cloexec(PA_PA_MACHINE_ID, "r"))) {
cf87a08b
JR
21+ char ln[34] = "", *r;
22+
23+ r = fgets(ln, sizeof(ln)-1, f);
24+ fclose(f);
25+
26+ pa_strip_nl(ln);
27+
28+ if (r && ln[0])
29+ return pa_utf8_filter(ln);
30+ }
31+
f105a6c8
JP
32 /* We search for the machine-id file from four locations. The first two are
33 * relative to the configured installation prefix, but if we're installed
34 * under /usr/local, for example, it's likely that the machine-id won't be
This page took 0.034368 seconds and 4 git commands to generate.