Commit graph

8092 commits

Author SHA1 Message Date
Alexander E. Patrakov
b094c92a01 Make pa_socket_server_new static
While at it, also remove SOCKET_SERVER_GENERIC, because it is always
being overwritten with a specific socket type.

Signed-off-by: Alexander E. Patrakov <patrakov@gmail.com>
2015-02-12 20:33:45 +01:00
Tanu Kaskinen
73dee7c9f7 socket-server: pa_socket_server_new() can't fail, so don't check its return value
An assertion was already used in pa_socket_server_new_unix(), this
makes the TCP variants consistent with that.

Even if pa_socket_server_new() could fail, the error handling wasn't
good, because there was no "goto fail", meaning that the fd would have
been leaked.
2015-02-12 20:33:44 +01:00
David Henningsson
53ad8aa7ca Update NEWS file
Some more contributors during the RC cycle.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2015-02-12 15:09:38 +01:00
Tanu Kaskinen
82ec47898e alsa: Don't try to use ELD controls with UCM
This fixes a crash that occurred when trying to access non-existent
port data. Doing this:

    pa_alsa_port_data *data = PA_DEVICE_PORT_DATA(port);

is not a good idea when using UCM, because in the UCM mode ports don't
have any data, so the data pointer points to some random memory.
2015-02-12 15:06:59 +02:00
Arun Raghavan
ff5e7b8707 shell-completion: bash: Fix pactl list source-outputs 2015-02-03 11:33:45 +05:30
Georg Chini
d6ef0ec3dc loopback: Don't push zero-sized block to memblockq
During my work on module-loopback I found a bug that sometimes crashes pulse when
module-loopback is loaded due to pushing a zero-length block into the memblockq.
As there is a one-line fix I thought you might want it for 6.0.
2015-02-02 13:17:35 +02:00
Arun Raghavan
a4c600e375 build-sys: libwebrtc-util needs libpulsecore 2015-02-02 13:13:36 +02:00
David Henningsson
5cc3d4aa9d alsa-mixer: Make speaker unavailable when Line Out is plugged in
ALSA mutes speaker when Line Out is plugged in by default, so
we should follow that convention.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2015-01-29 10:24:35 -05:00
Tanu Kaskinen
f75335f25c alsa-mixer: Add lineout to surround21 mappings
This makes the analog-surround-21 mapping consistent with other
surround mappings. I'm not sure if this makes any practical
difference, though.
2015-01-29 10:18:41 -05:00
David Henningsson
bf53143387 module-device-restore: Fix memory leak in read_sink_format_reply
This function could sometimes leak a perportentry.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2015-01-29 10:18:38 -05:00
David Henningsson
34862dbd43 protocol-native: Disable srbchannel by default
Recent testing has shown some srbchannel related bugs that
indicates that the srbchannel feature is not ready to be enabled
by default.

Therefore, temporary disable it for the 6.0 release and re-enable
it in git master once 6.0 is released.

Bugs:
https://bugs.freedesktop.org/show_bug.cgi?id=88452
https://bugs.freedesktop.org/show_bug.cgi?id=88167

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2015-01-21 15:06:53 +01:00
Ondrej Holecek
5effc83479 update FSF addresses to FSF web page
FSF addresses used in PA sources are no longer valid and rpmlint
generates numerous warnings during packaging because of this.
This patch changes all FSF addresses to FSF web page according to
the GPL how-to: https://www.gnu.org/licenses/gpl-howto.en.html

Done automatically by sed-ing through sources.
2015-01-14 22:20:40 +02:00
Tanu Kaskinen
1738e1ab60 i18n: Fix up the Turkish translation
The translation was not added to LINGUAS and there was this error from
msgfmt:

tr.po:2801: 'msgid' and 'msgstr' entries do not both begin with '\n'
2015-01-13 22:38:29 +02:00
kozdincer
8658709ed3 i18n: Add Turkish translation 2015-01-13 22:33:29 +02:00
David Henningsson
9d0a5b5cb7 alsa-mixer: Mute headphones and speakers on line out path
When line out path is active, we want to mute speakers for obvious
reasons, and headphones to avoid volume spikes.

Reported-by: TienFu Chen <tienfu.chen@canonical.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2015-01-13 13:58:01 +01:00
Boris Egorov
f5c001af5f pacmd: add missing 'else' keyword
See code above for proper behavior.

Issue detected by PVS Studio
2015-01-13 11:27:47 +01:00
Boris Egorov
1931e40b1c tunnel: use proper value for pa_source_state switch
pa_source_state_t can have value PA_SOURCE_INVALID_STATE, not
PA_SINK_INVALID_STATE. It happens to be the same here, but it can break
sometimes.

Issue detected by PVS Studio.
2015-01-13 11:27:46 +01:00
Boris Egorov
3e6ce485f0 alsa-util: fix parenthesis position in err assignment
Issue detected by CppCheck and PVS Studio
2015-01-13 11:27:46 +01:00
Wim Taymans
50186d7fcb svolume.orc: avoid parameter loading undefined behaviour
In some cases, depending on the instruction that performs the load, orc
ignores the size of the parameter when loading it for the first time.
Explicitly load the parameter into a temp to make sure it is loaded
correctly, like we do for the 2ch case.

See https://bugzilla.gnome.org/show_bug.cgi?id=742271
2015-01-12 13:56:29 +05:30
David Henningsson
112a39fa43 memblock: Fix more block ID collisions
Since the srb memblock and the audio data were coming from separate
pools, and the base index was per pool, they could actually still
collide.

This patch changes the base index to be global and atomically
incremented.

Reported-by: Arun Raghavan <arun@accosted.net>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2015-01-08 16:10:50 +01:00
Felipe Sateler
4edc15346b pactl: fix getopt indexing for set-*-volume
When pactl is invoked with any options or the -- specifier, optind will
be > 1. Therefore using a static 3 value is wrong. Use optind+2 as both
offset and count difference.

Bug-Debian: http://bugs.debian.org/774810
2015-01-08 13:25:02 +01:00
Tanu Kaskinen
ce950b150d build-sys: Don't enable libsamplerate by default
The libsamplerate based resamplers have been deprecated, so it's best
to not build them by default.
2015-01-05 16:14:19 +02:00
Tanu Kaskinen
e0e0ebb03f tunnel-sink-new: Fix stale audio on resume
I noticed that when resuming the tunnel sink, there was a small amount
of previously played audio before the new audio started to play.
Normally that probably wouldn't be noticeable, because there would be
a few seconds of silence played before suspending the sink due to
inactivity, so the unwanted old audio would be just silence, but in my
configuration sinks are suspended immediately when there's nothing
playing to them, so the glitch becomes audible.
2015-01-02 14:33:05 +02:00
Josef Andersson
ab830d887c i18n: Update the Swedish translation 2014-12-29 16:01:26 +02:00
Alexander E. Patrakov
01ae1c1f88 Fix the WhatIsWrongWithSystemWide URL
Pavel Machek reported in his blog that our message about the system mode
has a dead link in it. And this link is also present in translations.
So, I replaced it in the source and fixed all translations using a script:

for a in po/*.po ; do msgcat --no-wrap $a | sed
's@http://pulseaudio.org/wiki/WhatIsWrongWithSystemMod
@http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode @g' | sed
's@http://pulseaudio.org/wiki/WhatIsWrongWithSystemMode@http://www.freedesktop.org/wiki/Software/PulseAudio/Documentation/User/WhatIsWrongWithSystemWide/@g'
| sed 's@/\.@/ .@g' | sed 's@/,@/ ,@g' | msgcat - > $a.new

git add -i  # to filter out formatting changes

The "/." and "/," replacements are needed so that various terminal
emulators don't include the trailing "." or "," into the clickable URL.

The resulting patch is attached, just in case, in order to avoid
damaging non-ASCII characters.

--
Alexander E. Patrakov

>From 7dcd197571840e467d688f0f7354253730bbcc15 Mon Sep 17 00:00:00 2001
From: "Alexander E. Patrakov" <patrakov@gmail.com>
Date: Sat, 29 Nov 2014 20:56:27 +0500
Subject: [PATCH] Fix the WhatIsWrongWithSystemWide URL

Reported by Pavel Machek in http://pavelmachek.livejournal.com/126190.html

All translations were also fixed using a script.

Signed-off-by: Alexander E. Patrakov <patrakov@gmail.com>
2014-12-29 15:41:27 +02:00
Alexander E. Patrakov
6e4e8621a6 Fix URLs still pointing to the old wiki
Signed-off-by: Alexander E. Patrakov <patrakov@gmail.com>
2014-12-22 12:59:23 +02:00
David Henningsson
d9854577c3 Revert "launch: Disable autospawn by default when systemd daemon support is enabled."
This reverts commit 7276faca72.

Using the new systemd socket activation for PulseAudio will cause PulseAudio to not
have any connection with D-Bus, breaking device reservation protocol, module-jackdbus-detect
and module-dbus-protocol. Therefore, autospawn is now still enabled by default even if you
build with systemd daemon headers.
2014-12-19 13:46:11 +01:00
Tanu Kaskinen
1d3fd4f862 card-restore: Fix profile restoring with bluetooth
The bluetooth card is created when the first profile becomes
available, which means that the card may have profiles that are not
available when the card is initialized. If module-card-restore tries
to restore such profile, that will fail, and the card will be
initialized with the "off" profile active.

This patch modifies module-card-restore so that if follows the profile
availability status, and when the saved profile becomes available, it
is activated. Additionally, module-card-restore is modified so that it
doesn't even try to restore unavailable profiles, when the necessary
information is available. In practice there are two existing places
where the profile is restored, and only one of those contexts has the
necessary information available. Unfortunately, it's the more
important context (card creation) where the information is not
available. This means that module-card-restore will set the initial
profile of a new card even if the profile is unavailable, and this
will cause an ugly warning in the log, even though there's nothing
abnormal happening.

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=87081
2014-12-19 11:51:13 +01:00
David Henningsson
de1e78a47c bluez5: Do not suspend on no -> unknown profile transitions
In case a transport is currently disconnected and transitions to
idle, that should not count as a "remote hang up" event.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-12-19 11:50:28 +01:00
Arun Raghavan
6027cb52d9 introspect: Minor documentation fix 2014-12-15 11:48:08 +05:30
David Henningsson
9e65fd1373 memblock: Initialize mempool object to zero
This fixes a "use of uninitialised value" error in previous memblock commit.

Reported-by: Alexander Patrakov <patrakov@gmail.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-12-10 14:28:45 +01:00
David Henningsson
e175796fa5 srbchannel: Check return value of pa_memblock_new_pool
In case PA_MEMPOOL_DISABLE is set, pa_memblock_new_pool can return
NULL. It does not make sense to set up a srbchannel without a shared
memory pool, so just fail in this case.

Reported-by: Alexander Patrakov <patrakov@gmail.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-12-08 14:12:02 +01:00
Tanu Kaskinen
ce7ff172b8 i18n: Add French translation for "Speaker"
BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=87073
2014-12-08 15:05:13 +02:00
Alexander E. Patrakov
e2a433b222 Warn on loading module-dbus-protocol
See also
https://www.mail-archive.com/ubuntu-audio-dev@lists.launchpad.net/msg00268.html

The warning may be useful for users who carried over the module-loading
statement from default configuration files shipped with old PulseAudio
versions.

Signed-off-by: Alexander E. Patrakov <patrakov@gmail.com>
2014-12-08 14:23:53 +02:00
Jason Newton
162adb9873 module-equalizer-sink: remove erroneous fixme
pa_memblockq_drop is guaranteed to drop the chunk we just extracted from the
memblockq which internally unrefs the chunk.
2014-12-08 10:25:44 +01:00
Jason Newton
7201c9be98 module-equalizer-sink: use fftwf_free in all the right places
Several mallocs were made using fftwf_malloc and were erroneously freed by
pa_xfree. This patch corrects these calls of pa_xfree to fftwf_free.
2014-12-08 10:25:40 +01:00
Alexander E. Patrakov
d72cb78d4c Warn on loading module-equalizer-sink
See objections to the code in this email:

http://lists.freedesktop.org/archives/pulseaudio-discuss/2014-March/020174.html
Signed-off-by: Alexander E. Patrakov <patrakov@gmail.com>
2014-12-08 10:22:43 +01:00
David Henningsson
baf7b985fb memblock: Avoid block ID collisions when exporting memory blocks
Every new memexport object now gets an ever increasing base index,
that prevents block ID collisions between different memexport
objects on the same pstream.

In particular, this prevents block ID collision between the srb memblock
(which has its own memexport object) and audio data blocks.

Reported-by: Peter Meerwald <pmeerw@pmeerw.net>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-12-08 09:09:38 +01:00
Tanu Kaskinen
2b6632e851 module: Fix unsafe iteration
This fixes an issue when requesting module unload for
module-bluetooth-discover. When unloading the module, it also unloads
module-bluez4-discover and/or module-bluez5-discover, and that
invalidated the state variable that was used for iterating through the
modules idxset.

The pa_module.unload_requested flag could now otherwise be removed,
but it's still being (ab)used in the bluetooth modules.
2014-12-05 16:07:59 +02:00
David Henningsson
686baf80d9 core-util: Fix build on mingw32
mingw32 does not have "getuid", so ifdef it properly.

Reported-by: Michael DePaulo <mikedep333@gmail.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-12-04 15:39:03 +01:00
David Henningsson
9793870b23 bluez5: Fix free order of adapters and devices
Because the adapters reference the devices hashmap on free, we mush
free the adapters hashmap first and then the devices hashmap.

Reported-by: Alexander Patrakov <patrakov@gmail.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-12-03 12:04:29 +01:00
David Henningsson
580f468900 build-sys: Don't build srbchannel-test on targets without srbchannel
Reported-by: Felipe Sateler <fsateler@debian.org>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-12-03 11:48:52 +01:00
Felipe Sateler
13a3daa928 Fix #defines for Debian GNU/kFreeBSD
Because debian does not run with the freebsd libc, but rather uses the
GNU one, it chose to not define __FreeBSD__, but rather __FreeBSD_kernel__.
Use the alternative when the functionality tested is for kernel
features, and keep the __FreeBSD__ one when using freebsd libc
headers.

If this patch is applied, debian could drop all the current patches when
importing 6.0 :)
2014-12-01 12:11:07 +01:00
Yuri Chornoivan
5cae5fc848 Update Ukrainian translation 2014-12-01 00:06:40 +02:00
Piotr Drąg
0be32bce60 Updated Polish translation 2014-12-01 00:01:43 +02:00
Tanu Kaskinen
7856a7bf06 build-sys: Fix the BlueZ 5 native headset backend check
If the libbluetooth headers aren't available, we shouldn't treat that
as an error unless --enable-bluez5-native-headset has been explicitly
given to configure.

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=86582
2014-11-24 11:49:43 +02:00
Tanu Kaskinen
2df47d1519 build-sys: Always define bluetooth related HAVE_* variables
I don't know if it can cause any problems if HAVE_BLUEZ_4,
HAVE_BLUEZ_5, HAVE_BLUEZ, HAVE_BLUEZ_5_OFONO_HEADSET or
HAVE_BLUEZ_5_NATIVE_HEADSET are undefined when the corresponding
features are not enabled, but it certainly won't hurt to define the
variables also when the features are not enabled.
2014-11-24 11:49:41 +02:00
Tanu Kaskinen
660aa90322 NEWS: Zsh completion support isn't new in 6.0
There have been several fixes to the Zsh completion during the current
development cycle, but the completion was initially implemented
already in 4.0.
2014-11-24 11:49:16 +02:00
Cheng-Chia Tseng
aa765a38f4 i18n: update Chinese (traditional) translation 2014-11-23 14:30:14 +02:00
David Henningsson
457ab20f15 po: add pulseaudio.service.in to POTFILES.in
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-11-21 14:36:36 +01:00