summaryrefslogtreecommitdiff
path: root/src/pulse
AgeCommit message (Collapse)AuthorFilesLines
2015-03-06b2g: Add initial B2G policy moduleArun Raghavan2-0/+275
For now, provides a simple interface to add a per-stream-type volume factor to sink-inputs.
2015-03-06FIXME: Misc Android-specific fixesArun Raghavan1-0/+3
2015-01-14update FSF addresses to FSF web pageOndrej Holecek67-204/+68
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.
2014-12-19Revert "launch: Disable autospawn by default when systemd daemon support is ↵v5.99.2David Henningsson2-5/+1
enabled." This reverts commit 7276faca72e9696d4891daff139aee52509f43bf. 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-15introspect: Minor documentation fixArun Raghavan1-1/+1
2014-11-03launch: Disable autospawn by default when systemd daemon support is enabled.Colin Guthrie2-1/+5
When enabled, this method is prefered over pulseaudio's built in systems so we should try our best to ensure that it cannot be spawned outside of the mechanisms desired. Packagers should call 'systemctl --global enable pulseaudio.socket' to enable the socket for all users, or alternatively ship an enabling symlink in /usr/lib/systemd/user/sockets.target.wants/ folder. It may also make sense for distributions to add in a ConditionNNN= line to the socket unit if they have a downstream mechanism for enabling or disabling pulseaudio. If individual users wish to opt out of this vendor (or administrator) decision, they can call 'systemctl --user mask pulseaudio.socket'
2014-10-31creds: Rename pa_ancil to pa_cmsg_ancil_dataArun Raghavan1-2/+2
Makes the purpose of the structure clearear.
2014-10-28mainloop: Fix typoPeter Meerwald1-2/+2
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-10-28Cleanup !! for boolPeter Meerwald1-2/+2
!!x makes no sense if x is bool (this is a leftover from the convertion pa_bool_t -> bool, d806b197) Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-10-24stream: Fail on client submitting non-frame-aligned memblocksDavid Henningsson1-0/+2
If somebody tries to push a non-frame-aligned memblock onto the memblockq, then we should fail the write. Otherwise the daemon will crash, see https://bugs.freedesktop.org/show_bug.cgi?id=77595 Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-10-17pulse: Initalise pa_threaded_mainloop with zeroesArun Raghavan1-6/+1
2014-10-16util: Try finding out application name using dladdr if availableFelipe Sateler1-0/+23
This fixes getting the binary name in the Hurd, or any other port using the GNU C library, but only in the case where the library is directly linked to. Opening with dlopen will not work. Change in v3: reorder header includes and definitions Change in v2: use a weak reference to main, so that we don't crash when main cannot be found.
2014-09-10Client API: Add pa_stream_write_ext_free() function.Lukasz Marek2-3/+26
New function allows to pass data pointer that is a member of the outer structure that need to be freed too when data is not needed anymore. Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-09-02Replace "authorization" with "authentication"David Henningsson2-2/+2
Since we don't have "limited" clients, a client that authenticates correctly is automatically authorized. However, it's the authentication that can go wrong, rather than the authorization. Buglink: https://bugs.freedesktop.org/show_bug.cgi?id=78566 Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-09-02Make all debug/info level messages untranslatableDavid Henningsson1-1/+1
Debug and info messages are primarily meant for developers, rather than end users. Let's save translators' time, and leave them untranslated. Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-08-24device-manager: Don't allow setting an empty description in the client APITanu Kaskinen1-0/+1
The module implementation treats an empty description as a protocol error, so we should validate the description already at client side.
2014-08-22format: Don't use deprecated json-c is_error() macroPeter Meerwald1-8/+8
json_tokener_parse() simply returns NULL on error these days latest json-c (post 0.12) doesn't automatically include json-c/bits.h anymore causing compilation errors Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-08-22format: Use json_object_object_get_ex() instead of deprecated ↵Peter Meerwald1-10/+8
json_object_object_get() pulse/format.c: In function 'pa_format_info_get_prop_type': pulse/format.c:252:5: warning: implicit declaration of function 'is_error' [-Wimplicit-function-declaration] pulse/format.c:287:13: warning: 'json_object_object_get' is deprecated (declared at /usr/local/include/json-c/json_object.h:290) [-Wdeprecated-declarations] pulse/format.c:293:13: warning: 'json_object_object_get' is deprecated (declared at /usr/local/include/json-c/json_object.h:290) [-Wdeprecated-declarations] pulse/format.c: In function 'pa_format_info_get_prop_int_range': pulse/format.c:364:5: warning: 'json_object_object_get' is deprecated (declared at /usr/local/include/json-c/json_object.h:290) [-Wdeprecated-declarations] pulse/format.c:369:5: warning: 'json_object_object_get' is deprecated (declared at /usr/local/include/json-c/json_object.h:290) [-Wdeprecated-declarations] pulse/format.c: In function 'pa_format_info_prop_compatible': pulse/format.c:676:9: warning: 'json_object_object_get' is deprecated (declared at /usr/local/include/json-c/json_object.h:290) [-Wdeprecated-declarations] pulse/format.c:680:9: warning: 'json_object_object_get' is deprecated (declared at /usr/local/include/json-c/json_object.h:290) [-Wdeprecated-declarations] json-c 0.10 (released 20120530) added json_object_object_get_ex() json-c 0.12 (released 20140410) deprecated json_object_object_get() PulseAudio depends on json 0.9 or json-c 0.11, drop support for json 0.9 in a subsequent patch and require json-c 0.11 (this will also avoids confusion which json package is needed due to the upstream rename) Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-08-22format: Don't _put() objects obtained with json_object_object_get() or ↵Peter Meerwald1-9/+0
json_object_array_get_idx() json-c documentation states that "No reference counts will be changed. There is no need to manually adjust reference counts through the json_object_put/json_object_get methods unless..." hence fix pa_format_info_get_prop_type() and pa_format_info_get_prop_int_range(); note that pa_format_info_prop_compatible() is OK the json_object_array_get_idx() bug reported by Arun, thanks! Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Cc: Arun Raghavan <arun@accosted.net>
2014-08-18context: Handle client-side failure of pa_srbchannel_new_from_template()Peter Meerwald1-0/+4
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Cc: David Henningsson <david.henningsson@canonical.com>
2014-08-18context: Stop and return if srbchannel memblock looks fishyPeter Meerwald1-3/+7
handle_srbchannel_memblock() should return when memblock sanity checks fail Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Cc: David Henningsson <david.henningsson@canonical.com>
2014-08-12util: Fix pa_get_binary_name() on Debian/kFreeBSDPeter Meerwald1-2/+2
Debian GNU/kFreeBSD uses a FreeBSD kernel and GLIBC, it #defines __FreeBSD_kernel__, but not __FreeBSD__ nor __linux__ Debian GNU/kFreeBSD does have a /proc/self/exe FreeBSD #defines __FreeBSD__ and __FreeBSD_kernel__ problem reporte here: http://lists.freedesktop.org/archives/pulseaudio-discuss/2014-July/020998.html http://stackoverflow.com/questions/1023306/finding-current-executables-path-without-proc-self-exe and http://stackoverflow.com/questions/933850/how-to-find-the-location-of-the-executable-in-c have some background info Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-07-28simple: Take locally buffered data into account in pa_simple_get_latency()Tanu Kaskinen1-3/+18
BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=81075
2014-07-12device-manager: Add a comment about non-extensible structTanu Kaskinen1-0/+3
This comment can potentially save a lot of debugging effort and fixing an ABI break, even though I don't think it's particularly likely that anyone will ever extend pa_ext_device_manager_role_priority_info.
2014-07-04creds: Unbreak build without HAVE_CREDSDavid Henningsson1-0/+7
A recent patch broke the build on FreeBSD, which does not have HAVE_CREDS defined. Also, make sure any attempts to enable the srbchannel on such architectures fail. BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=80642 Reported-by: Ryan Lortie Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-06-27Protocol, client: Add commands to enable srbchannelDavid Henningsson2-1/+110
This increments protocol version to v30 and adds two new commands to enable and disable an shm ringbuffer, as well as client side implementation. Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-06-27iochannel/pstream/pdispatch: Add support for receiving file descriptorsDavid Henningsson1-2/+2
The file descriptors are read from the iochannel just like the creds are. So instead of passing just creds (and creds_valid), we now pass the entire pa_ancil struct. Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-06-27client-conf: add missing directory to pulse/client-conf.x11.h includeEvan Nemerson1-1/+1
https://bugs.freedesktop.org/show_bug.cgi?id=80570
2014-06-24esound, native: Pass an absolute path to pa_authkey_load() when using a file ↵Tanu Kaskinen1-3/+7
in the home directory If a relative path is passed to pa_authkey_load(), it will interpret the path as relative to the home directory. This is wrong, because relative paths should be interpreted to be relative to the config home directory. Before fixing pa_authkey_load(), this patch prepares for the change by using absolute paths when the file actually needs to be in the home directory (i.e. the fallback cookie path for the native protocol and the default cookie path for the esound protocol).
2014-06-24authkey: Rename pa_authkey_load_auto() to pa_authkey_load()Tanu Kaskinen1-6/+6
pa_authkey_load() was removed earlier, so the _auto suffix isn't necessary any more.
2014-06-24client-conf: Move x11 and env loading to pa_client_conf_load()Tanu Kaskinen3-53/+55
This simplifies the code a bit.
2014-06-24client-conf: Don't report failure from pa_client_conf_load()Tanu Kaskinen2-18/+9
pa_context already ignored the return value of pa_client_conf_load(), so the only places where the return value was not ignored were the D-Bus server lookup thing and pax11publish. I don't think those cases are negatively affected if they ignore errors in opening or parsing client.conf. pa_client_conf_env() never failed anyway, so returning int was obviously redundant.
2014-06-06mainloop: avoid race-y double wakeup statusPierre Ossman1-7/+2
Having an extra variable that tracks the wakeup status introduces a race where the variable is set but the data has yet to propagate from the write end of the pipe to the read end. When this happens the system goes into a tight loop as select() always returns immediately.
2014-05-27channelmap: Add 2.1 surroundDavid Henningsson1-0/+6
Add surround-21 as a alias to set up a 2.1 channel map. Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2014-04-17Use pa_hashmap_remove_and_free() where appropriateTanu Kaskinen1-4/+1
2014-03-28client-conf: Don't create multiple cookie filesTanu Kaskinen4-88/+104
The old code loaded cookies at the time of loading the client configuration, which could lead to creation of multiple cookie files. For example, when pa_client_conf_load() was called, the default cookie file was created, and then if PULSE_COOKIE was set, pa_client_conf_env() would create another cookie file. This patch moves the loading of the cookie to a separate function, which pa_context calls just before needing the cookie, so the cookie won't be loaded from the default file if PULSE_COOKIE is set. This patch also splits the single cookie and cookie_file fields in pa_client_conf into multiple fields, one for each possible cookie source. That change allows falling back to another cookie source if the primary source doesn't work. BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=75006
2014-03-28client-conf: Remove redundant function parametersTanu Kaskinen5-26/+14
2014-03-28util: Check that the home dir is an absolute pathTanu Kaskinen1-10/+22
Avoid unpredictable behaviour in case e.g. the HOME environment variable is incorrectly set up for whatever reason. I haven't seen non-absolute HOME anywhere, but this feels like a good sanity check anyway.
2014-03-27introspect: Use pa_direction_valid() to validate port directionTanu Kaskinen1-3/+3
There's no behavioral change, just nicer code.
2014-03-27direction: Add a couple of direction helper functionsTanu Kaskinen3-2/+86
2014-03-15mainloop-api: Improve pa_mainloop_api_once() documentationTanu Kaskinen1-3/+5
2014-03-14volume: Increase PA_SW_VOLUME_SNPRINT_DB_MAXTanu Kaskinen1-1/+1
10 bytes isn't enough for "-123.45 dB", including the terminating null byte.
2014-03-08doc: Use \since doxygen command correctly in mainloop-api.hPeter Meerwald1-3/+3
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-03-08doc: Use correct parameter name wait_for_accept in documentation of ↵Peter Meerwald1-2/+2
pa_threaded_mainloop_signal() also sneaks in a full stop in documentation elsewhere Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-03-07Fix a few "it's -> its" typosAlexander E. Patrakov1-1/+1
2014-03-06doc: Fix pa_stream_set_latency_update_callback() documentationPeter Meerwald1-1/+1
the latency_update callback is supported on playback AND record streams Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-03-06doc: Fix a couple of 'to to' typosPeter Meerwald1-1/+1
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-02-23doc: Assorted spelling and grammar fixes for doxygen outputPeter Meerwald4-7/+7
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2014-01-23introspect, thread-mainloop: Fix Doxygen "since" tagsTanu Kaskinen2-4/+4
2014-01-08format: Add some error loggingTanu Kaskinen1-5/+26