diff options
author | Joe Marcus Clarke <marcus@FreeBSD.org> | 2009-09-11 03:45:50 +0000 |
---|---|---|
committer | Joe Marcus Clarke <marcus@FreeBSD.org> | 2009-09-11 03:45:50 +0000 |
commit | 41827391ecf209143a55f7f70520621ae44829a6 (patch) | |
tree | e7d5c605729219ee6feb015d22d56b6a068f8b87 /audio/pulseaudio | |
parent | d04ae109cc4def64fbd3b54b1936cd0a021262ca (diff) | |
download | ports-41827391ecf209143a55f7f70520621ae44829a6.tar.gz ports-41827391ecf209143a55f7f70520621ae44829a6.zip |
Notes
Diffstat (limited to 'audio/pulseaudio')
-rw-r--r-- | audio/pulseaudio/Makefile | 4 | ||||
-rw-r--r-- | audio/pulseaudio/distinfo | 6 | ||||
-rw-r--r-- | audio/pulseaudio/files/patch-src_Makefile.in | 14 | ||||
-rw-r--r-- | audio/pulseaudio/files/patch-src_daemon_main.c | 10 | ||||
-rw-r--r-- | audio/pulseaudio/files/patch-src_modules_module-hal-detect.c | 11 | ||||
-rw-r--r-- | audio/pulseaudio/files/patch-src_pulsecore_core-util.c | 49 | ||||
-rw-r--r-- | audio/pulseaudio/files/patch-ubuntu-bundle | 881 | ||||
-rw-r--r-- | audio/pulseaudio/pkg-message | 6 | ||||
-rw-r--r-- | audio/pulseaudio/pkg-plist | 19 |
9 files changed, 29 insertions, 971 deletions
diff --git a/audio/pulseaudio/Makefile b/audio/pulseaudio/Makefile index 3889fa8fcb46..506ea30b2617 100644 --- a/audio/pulseaudio/Makefile +++ b/audio/pulseaudio/Makefile @@ -7,8 +7,7 @@ # PORTNAME= pulseaudio -PORTVERSION= 0.9.15 -PORTREVISION= 5 +PORTVERSION= 0.9.17 CATEGORIES= audio MASTER_SITES= http://0pointer.de/lennart/projects/${PORTNAME}/ @@ -16,7 +15,6 @@ MAINTAINER= gnome@FreeBSD.org COMMENT= Sound server for UNIX LIB_DEPENDS= samplerate.1:${PORTSDIR}/audio/libsamplerate \ - oil-0.3.0:${PORTSDIR}/devel/liboil \ speexdsp.1:${PORTSDIR}/audio/speex \ dbus-1.3:${PORTSDIR}/devel/dbus \ gdbm.3:${PORTSDIR}/databases/gdbm \ diff --git a/audio/pulseaudio/distinfo b/audio/pulseaudio/distinfo index 3a94651289a0..8c69266256b0 100644 --- a/audio/pulseaudio/distinfo +++ b/audio/pulseaudio/distinfo @@ -1,3 +1,3 @@ -MD5 (pulseaudio-0.9.15.tar.gz) = 4510364eeab219fd100bd1b373b1a002 -SHA256 (pulseaudio-0.9.15.tar.gz) = 1e8ad5b7c5cf3485bd0738c296274ff2c99d26d12a25a225dc250eddea25b9f1 -SIZE (pulseaudio-0.9.15.tar.gz) = 1704374 +MD5 (pulseaudio-0.9.17.tar.gz) = cba8f14b8213f47e1d35da3a0a3cb076 +SHA256 (pulseaudio-0.9.17.tar.gz) = 9c25c09218c7b6697daa379287443f6183829556990475a2f6d198e85e3119f0 +SIZE (pulseaudio-0.9.17.tar.gz) = 1995665 diff --git a/audio/pulseaudio/files/patch-src_Makefile.in b/audio/pulseaudio/files/patch-src_Makefile.in index 0be2eaa8c063..e3782e935ebe 100644 --- a/audio/pulseaudio/files/patch-src_Makefile.in +++ b/audio/pulseaudio/files/patch-src_Makefile.in @@ -1,11 +1,11 @@ ---- src/Makefile.in.orig 2009-07-19 14:49:35.000000000 -0400 -+++ src/Makefile.in 2009-07-19 14:56:39.000000000 -0400 -@@ -2668,7 +2668,7 @@ libpulsecommon_@PA_MAJORMINORMICRO@_la_C +--- src/Makefile.in.orig 2009-09-10 22:40:54.000000000 -0400 ++++ src/Makefile.in 2009-09-10 22:42:31.000000000 -0400 +@@ -2890,7 +2890,7 @@ libpulsecommon_@PA_MAJORMINORMICRO@_la_C libpulsecommon_@PA_MAJORMINORMICRO@_la_LDFLAGS = $(AM_LDFLAGS) \ - -avoid-version $(am__append_17) + -avoid-version $(am__append_14) libpulsecommon_@PA_MAJORMINORMICRO@_la_LIBADD = $(AM_LIBADD) \ -- $(LIBWRAP_LIBS) $(WINSOCK_LIBS) $(LTLIBICONV) $(am__append_19) \ -+ $(LIBWRAP_LIBS) $(WINSOCK_LIBS) $(LTLIBICONV) -lexecinfo $(am__append_19) \ - $(am__append_23) +- $(LIBWRAP_LIBS) $(WINSOCK_LIBS) $(LTLIBICONV) \ ++ $(LIBWRAP_LIBS) $(WINSOCK_LIBS) $(LTLIBICONV) -lexecinfo \ + $(LIBSNDFILE_LIBS) $(am__append_16) $(am__append_20) ################################### diff --git a/audio/pulseaudio/files/patch-src_daemon_main.c b/audio/pulseaudio/files/patch-src_daemon_main.c deleted file mode 100644 index 95a929a4b75a..000000000000 --- a/audio/pulseaudio/files/patch-src_daemon_main.c +++ /dev/null @@ -1,10 +0,0 @@ ---- src/daemon/main.c.orig 2009-01-12 18:11:38.000000000 -0500 -+++ src/daemon/main.c 2009-03-07 19:56:16.000000000 -0500 -@@ -37,6 +37,7 @@ - #include <unistd.h> - #include <locale.h> - #include <sys/types.h> -+#include <sys/stat.h> - - #include <liboil/liboil.h> - diff --git a/audio/pulseaudio/files/patch-src_modules_module-hal-detect.c b/audio/pulseaudio/files/patch-src_modules_module-hal-detect.c deleted file mode 100644 index fd7f8bd45e52..000000000000 --- a/audio/pulseaudio/files/patch-src_modules_module-hal-detect.c +++ /dev/null @@ -1,11 +0,0 @@ ---- src/modules/module-hal-detect.c.orig 2009-04-04 20:16:18.000000000 -0500 -+++ src/modules/module-hal-detect.c 2009-08-16 16:09:49.000000000 -0500 -@@ -293,7 +293,7 @@ - - /* We only care for the main device */ - device = libhal_device_get_property_int(context, udi, "oss.device", &error); -- if (dbus_error_is_set(&error) || device != 0) -+ if (dbus_error_is_set(&error)) - goto finish; - - r = TRUE; diff --git a/audio/pulseaudio/files/patch-src_pulsecore_core-util.c b/audio/pulseaudio/files/patch-src_pulsecore_core-util.c deleted file mode 100644 index 91f369249354..000000000000 --- a/audio/pulseaudio/files/patch-src_pulsecore_core-util.c +++ /dev/null @@ -1,49 +0,0 @@ ---- src/pulsecore/core-util.c.orig 2008-09-08 19:33:30.000000000 -0400 -+++ src/pulsecore/core-util.c 2008-09-28 19:50:24.000000000 -0400 -@@ -37,6 +37,7 @@ - #include <time.h> - #include <ctype.h> - #include <sys/types.h> -+#include <sys/socket.h> - #include <sys/stat.h> - #include <sys/time.h> - #include <dirent.h> -@@ -567,6 +568,7 @@ int pa_make_realtime(int rtprio) { - errno = ENOTSUP; - return -1; - #endif -+ ; - } - - /* This is merely used for giving the user a hint. This is not correct -@@ -1131,22 +1133,22 @@ int pa_check_in_group(gid_t g) { - (advisory on UNIX, mandatory on Windows) */ - int pa_lock_fd(int fd, int b) { - #ifdef F_SETLKW -- struct flock flock; -+ struct flock pa_flock; - - /* Try a R/W lock first */ - -- flock.l_type = (short) (b ? F_WRLCK : F_UNLCK); -- flock.l_whence = SEEK_SET; -- flock.l_start = 0; -- flock.l_len = 0; -+ pa_flock.l_type = (short) (b ? F_WRLCK : F_UNLCK); -+ pa_flock.l_whence = SEEK_SET; -+ pa_flock.l_start = 0; -+ pa_flock.l_len = 0; - -- if (fcntl(fd, F_SETLKW, &flock) >= 0) -+ if (fcntl(fd, F_SETLKW, &pa_flock) >= 0) - return 0; - - /* Perhaps the file descriptor qas opened for read only, than try again with a read lock. */ - if (b && errno == EBADF) { -- flock.l_type = F_RDLCK; -- if (fcntl(fd, F_SETLKW, &flock) >= 0) -+ pa_flock.l_type = F_RDLCK; -+ if (fcntl(fd, F_SETLKW, &pa_flock) >= 0) - return 0; - } - diff --git a/audio/pulseaudio/files/patch-ubuntu-bundle b/audio/pulseaudio/files/patch-ubuntu-bundle deleted file mode 100644 index c1511d705711..000000000000 --- a/audio/pulseaudio/files/patch-ubuntu-bundle +++ /dev/null @@ -1,881 +0,0 @@ -From 876624e3147cf3deac847b11bde4b04988971eee Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Sun, 19 Apr 2009 19:02:16 +0200 -Subject: [PATCH 02/28] util: if NULL is passed to pa_path_get_filename() just hand it through - ---- - src/pulse/util.c | 3 ++- - src/pulse/util.h | 2 +- - 2 files changed, 3 insertions(+), 2 deletions(-) - -diff --git src/pulse/util.c src/pulse/util.c -index 54a188d..6f1e40a 100644 ---- src/pulse/util.c -+++ src/pulse/util.c -@@ -219,7 +219,8 @@ char *pa_get_binary_name(char *s, size_t l) { - char *pa_path_get_filename(const char *p) { - char *fn; - -- pa_assert(p); -+ if (!p) -+ return NULL; - - if ((fn = strrchr(p, PA_PATH_SEP_CHAR))) - return fn+1; -diff --git src/pulse/util.h src/pulse/util.h -index f6dd40c..ad85653 100644 ---- src/pulse/util.h -+++ src/pulse/util.h -@@ -51,7 +51,7 @@ char *pa_get_home_dir(char *s, size_t l); - char *pa_get_binary_name(char *s, size_t l); - - /** Return a pointer to the filename inside a path (which is the last -- * component). */ -+ * component). If passed NULL will return NULL. */ - char *pa_path_get_filename(const char *p); - - /** Wait t milliseconds */ -From 7f17882bae9d2b694f440d28dc9bb3fcf133fa1a Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Fri, 1 May 2009 04:13:15 +0200 -Subject: [PATCH 08/28] endian: fix LE/BE order for 24 bit accessor functions - ---- - src/pulsecore/endianmacros.h | 8 ++++---- - 1 files changed, 4 insertions(+), 4 deletions(-) - -diff --git src/pulsecore/endianmacros.h src/pulsecore/endianmacros.h -index 2257937..2b18cf8 100644 ---- src/pulsecore/endianmacros.h -+++ src/pulsecore/endianmacros.h -@@ -45,27 +45,27 @@ - #define PA_UINT32_SWAP(x) ( (uint32_t) ( ((uint32_t) (x) >> 24) | ((uint32_t) (x) << 24) | (((uint32_t) (x) & 0xFF00) << 8) | ((((uint32_t) (x)) >> 8) & 0xFF00) ) ) - #endif - --static inline uint32_t PA_READ24LE(const uint8_t *p) { -+static inline uint32_t PA_READ24BE(const uint8_t *p) { - return - ((uint32_t) p[0] << 16) | - ((uint32_t) p[1] << 8) | - ((uint32_t) p[2]); - } - --static inline uint32_t PA_READ24BE(const uint8_t *p) { -+static inline uint32_t PA_READ24LE(const uint8_t *p) { - return - ((uint32_t) p[2] << 16) | - ((uint32_t) p[1] << 8) | - ((uint32_t) p[0]); - } - --static inline void PA_WRITE24LE(uint8_t *p, uint32_t u) { -+static inline void PA_WRITE24BE(uint8_t *p, uint32_t u) { - p[0] = (uint8_t) (u >> 16); - p[1] = (uint8_t) (u >> 8); - p[2] = (uint8_t) u; - } - --static inline void PA_WRITE24BE(uint8_t *p, uint32_t u) { -+static inline void PA_WRITE24LE(uint8_t *p, uint32_t u) { - p[2] = (uint8_t) (u >> 16); - p[1] = (uint8_t) (u >> 8); - p[0] = (uint8_t) u; -From 11c17636d1d6c7eb4d6278869d3fa91715433ab2 Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Sun, 19 Apr 2009 19:04:50 +0200 -Subject: [PATCH 09/28] log: print file name only when we have it - ---- - src/pulsecore/log.c | 2 +- - 1 files changed, 1 insertions(+), 1 deletions(-) - -diff --git src/pulsecore/log.c src/pulsecore/log.c -index 60ea9c5..919ebe1 100644 ---- src/pulsecore/log.c -+++ src/pulsecore/log.c -@@ -285,7 +285,7 @@ void pa_log_levelv_meta( - - if ((_flags & PA_LOG_PRINT_META) && file && line > 0 && func) - pa_snprintf(location, sizeof(location), "[%s:%i %s()] ", file, line, func); -- else if (_flags & (PA_LOG_PRINT_META|PA_LOG_PRINT_FILE)) -+ else if ((_flags & (PA_LOG_PRINT_META|PA_LOG_PRINT_FILE)) && file) - pa_snprintf(location, sizeof(location), "%s: ", pa_path_get_filename(file)); - else - location[0] = 0; -From 977f59368ba55fac3fe21d7549bc0552daf07d91 Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Tue, 21 Apr 2009 21:24:33 +0200 -Subject: [PATCH 13/28] mutex: when we fail to fill in mutex into static mutex ptr free it again - ---- - src/pulsecore/mutex-posix.c | 2 ++ - 1 files changed, 2 insertions(+), 0 deletions(-) - -diff --git src/pulsecore/mutex-posix.c src/pulsecore/mutex-posix.c -index b3e5256..0ff4bee 100644 ---- src/pulsecore/mutex-posix.c -+++ src/pulsecore/mutex-posix.c -@@ -153,6 +153,8 @@ pa_mutex* pa_static_mutex_get(pa_static_mutex *s, pa_bool_t recursive, pa_bool_t - if ((pa_atomic_ptr_cmpxchg(&s->ptr, NULL, m))) - return m; - -+ pa_mutex_free(m); -+ - /* Him, filling in failed, so someone else must have filled in - * already */ - pa_assert_se(m = pa_atomic_ptr_load(&s->ptr)); -From 776b0817f79b475c9725b53c185484b5e3ff6fbb Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Tue, 26 May 2009 22:30:36 +0200 -Subject: [PATCH 14/28] oss: don't deadlock when we try to resume an OSS device that lacks a mixer - ---- - src/modules/oss/module-oss.c | 11 +++++++---- - 1 files changed, 7 insertions(+), 4 deletions(-) - -diff --git src/modules/oss/module-oss.c src/modules/oss/module-oss.c -index 9f7863f..aa5f918 100644 ---- src/modules/oss/module-oss.c -+++ src/modules/oss/module-oss.c -@@ -477,6 +477,7 @@ static void build_pollfd(struct userdata *u) { - pollfd->revents = 0; - } - -+/* Called from IO context */ - static int suspend(struct userdata *u) { - pa_assert(u); - pa_assert(u->fd >= 0); -@@ -526,6 +527,7 @@ static int suspend(struct userdata *u) { - return 0; - } - -+/* Called from IO context */ - static int unsuspend(struct userdata *u) { - int m; - pa_sample_spec ss, *ss_original; -@@ -616,10 +618,10 @@ static int unsuspend(struct userdata *u) { - - build_pollfd(u); - -- if (u->sink) -- pa_sink_get_volume(u->sink, TRUE, FALSE); -- if (u->source) -- pa_source_get_volume(u->source, TRUE); -+ if (u->sink && u->sink->get_volume) -+ u->sink->get_volume(u->sink); -+ if (u->source && u->source->get_volume) -+ u->source->get_volume(u->source); - - pa_log_info("Resumed successfully..."); - -@@ -631,6 +633,7 @@ fail: - return -1; - } - -+/* Called from IO context */ - static int sink_process_msg(pa_msgobject *o, int code, void *data, int64_t offset, pa_memchunk *chunk) { - struct userdata *u = PA_SINK(o)->userdata; - int ret; -From b8e05f113a44f46a91d3343e3e4a1eb15c98e1c9 Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Wed, 29 Apr 2009 04:13:07 +0200 -Subject: [PATCH 15/28] simple-protocol: don't hit an assert when we call connection_unlink() early - ---- - src/pulsecore/protocol-simple.c | 2 +- - 1 files changed, 1 insertions(+), 1 deletions(-) - -diff --git src/pulsecore/protocol-simple.c src/pulsecore/protocol-simple.c -index 44fe597..776d74b 100644 ---- src/pulsecore/protocol-simple.c -+++ src/pulsecore/protocol-simple.c -@@ -130,7 +130,7 @@ static void connection_unlink(connection *c) { - c->io = NULL; - } - -- pa_assert_se(pa_idxset_remove_by_data(c->protocol->connections, c, NULL) == c); -+ pa_idxset_remove_by_data(c->protocol->connections, c, NULL); - c->protocol = NULL; - connection_unref(c); - } -From bee02ee03fc82f447a358a564a4d922c0f29cfcf Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Wed, 29 Apr 2009 01:46:12 +0200 -Subject: [PATCH 16/28] idxset: add enumeration macro PA_IDXSET_FOREACH - ---- - src/pulsecore/idxset.h | 4 ++++ - 1 files changed, 4 insertions(+), 0 deletions(-) - -diff --git src/pulsecore/idxset.h src/pulsecore/idxset.h -index 7531ea3..6b9ff47 100644 ---- src/pulsecore/idxset.h -+++ src/pulsecore/idxset.h -@@ -103,4 +103,8 @@ unsigned pa_idxset_size(pa_idxset*s); - /* Return TRUE of the idxset is empty */ - pa_bool_t pa_idxset_isempty(pa_idxset *s); - -+ -+#define PA_IDXSET_FOREACH(e, s, idx) \ -+ for ((e) = pa_idxset_first((s), &(idx)); (e); (e) = pa_idxset_next((s), &(idx))) -+ - #endif -From b7eff401100af0de381fba66293d21aca7ff36fa Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Fri, 17 Apr 2009 20:30:09 +0200 -Subject: [PATCH 17/28] rescue-streams: when one stream move fails try to continue with the remaining ones - ---- - src/modules/module-rescue-streams.c | 16 ++++++---------- - 1 files changed, 6 insertions(+), 10 deletions(-) - -diff --git src/modules/module-rescue-streams.c src/modules/module-rescue-streams.c -index 4f616e0..7c99a9b 100644 ---- src/modules/module-rescue-streams.c -+++ src/modules/module-rescue-streams.c -@@ -77,12 +77,10 @@ static pa_hook_result_t sink_hook_callback(pa_core *c, pa_sink *sink, void* user - } - - while ((i = pa_idxset_first(sink->inputs, NULL))) { -- if (pa_sink_input_move_to(i, target, FALSE) < 0) { -+ if (pa_sink_input_move_to(i, target, FALSE) < 0) - pa_log_warn("Failed to move sink input %u \"%s\" to %s.", i->index, pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME), target->name); -- return PA_HOOK_OK; -- } -- -- pa_log_info("Sucessfully moved sink input %u \"%s\" to %s.", i->index, pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME), target->name); -+ else -+ pa_log_info("Sucessfully moved sink input %u \"%s\" to %s.", i->index, pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME), target->name); - } - - -@@ -121,12 +119,10 @@ static pa_hook_result_t source_hook_callback(pa_core *c, pa_source *source, void - pa_assert(target != source); - - while ((o = pa_idxset_first(source->outputs, NULL))) { -- if (pa_source_output_move_to(o, target, FALSE) < 0) { -+ if (pa_source_output_move_to(o, target, FALSE) < 0) - pa_log_warn("Failed to move source output %u \"%s\" to %s.", o->index, pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME), target->name); -- return PA_HOOK_OK; -- } -- -- pa_log_info("Sucessfully moved source output %u \"%s\" to %s.", o->index, pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME), target->name); -+ else -+ pa_log_info("Sucessfully moved source output %u \"%s\" to %s.", o->index, pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME), target->name); - } - - -From 79510a3b15652b04bffbb798221d27e8d16f4ce2 Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Fri, 1 May 2009 04:12:24 +0200 -Subject: [PATCH 18/28] sample: correctly pass s24-32 formats - ---- - src/pulse/sample.c | 8 ++++---- - 1 files changed, 4 insertions(+), 4 deletions(-) - -diff --git src/pulse/sample.c src/pulse/sample.c -index 1e67b03..ed7b1b0 100644 ---- src/pulse/sample.c -+++ src/pulse/sample.c -@@ -231,13 +231,13 @@ pa_sample_format_t pa_parse_sample_format(const char *format) { - else if (strcasecmp(format, "s24re") == 0) - return PA_SAMPLE_S24RE; - else if (strcasecmp(format, "s24-32le") == 0) -- return PA_SAMPLE_S24LE; -+ return PA_SAMPLE_S24_32LE; - else if (strcasecmp(format, "s24-32be") == 0) -- return PA_SAMPLE_S24BE; -+ return PA_SAMPLE_S24_32BE; - else if (strcasecmp(format, "s24-32ne") == 0 || strcasecmp(format, "s24-32") == 0) -- return PA_SAMPLE_S24NE; -+ return PA_SAMPLE_S24_32NE; - else if (strcasecmp(format, "s24-32re") == 0) -- return PA_SAMPLE_S24RE; -+ return PA_SAMPLE_S24_32RE; - - return -1; - } -From 397f517aafda4efd00532ba7f19e7045aa853c2a Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Fri, 1 May 2009 04:14:40 +0200 -Subject: [PATCH 19/28] sample-util: fix iteration loop when adjusting volume of s24 samples - ---- - src/pulsecore/sample-util.c | 8 ++++---- - 1 files changed, 4 insertions(+), 4 deletions(-) - -diff --git src/pulsecore/sample-util.c src/pulsecore/sample-util.c -index 3a9b384..a3e490b 100644 ---- src/pulsecore/sample-util.c -+++ src/pulsecore/sample-util.c -@@ -831,9 +831,9 @@ void pa_volume_memchunk( - - calc_linear_integer_volume(linear, volume); - -- e = (uint8_t*) ptr + c->length/3; -+ e = (uint8_t*) ptr + c->length; - -- for (channel = 0, d = ptr; d < e; d++) { -+ for (channel = 0, d = ptr; d < e; d += 3) { - int64_t t; - - t = (int64_t)((int32_t) (PA_READ24NE(d) << 8)); -@@ -854,9 +854,9 @@ void pa_volume_memchunk( - - calc_linear_integer_volume(linear, volume); - -- e = (uint8_t*) ptr + c->length/3; -+ e = (uint8_t*) ptr + c->length; - -- for (channel = 0, d = ptr; d < e; d++) { -+ for (channel = 0, d = ptr; d < e; d += 3) { - int64_t t; - - t = (int64_t)((int32_t) (PA_READ24RE(d) << 8)); -From 55244f7a07335115caf2b9cc57aecc0f8cd08030 Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Fri, 1 May 2009 04:14:02 +0200 -Subject: [PATCH 20/28] sample-util: properly allocate silence block for s24-32 formats - ---- - src/pulsecore/sample-util.c | 4 ++++ - 1 files changed, 4 insertions(+), 0 deletions(-) - -diff --git src/pulsecore/sample-util.c src/pulsecore/sample-util.c -index a3e490b..dda3883 100644 ---- src/pulsecore/sample-util.c -+++ src/pulsecore/sample-util.c -@@ -1181,6 +1181,8 @@ pa_memchunk* pa_silence_memchunk_get(pa_silence_cache *cache, pa_mempool *pool, - case PA_SAMPLE_S32BE: - case PA_SAMPLE_S24LE: - case PA_SAMPLE_S24BE: -+ case PA_SAMPLE_S24_32LE: -+ case PA_SAMPLE_S24_32RE: - case PA_SAMPLE_FLOAT32LE: - case PA_SAMPLE_FLOAT32BE: - cache->blocks[PA_SAMPLE_S16LE] = b = silence_memblock_new(pool, 0); -@@ -1189,6 +1191,8 @@ pa_memchunk* pa_silence_memchunk_get(pa_silence_cache *cache, pa_mempool *pool, - cache->blocks[PA_SAMPLE_S32BE] = pa_memblock_ref(b); - cache->blocks[PA_SAMPLE_S24LE] = pa_memblock_ref(b); - cache->blocks[PA_SAMPLE_S24BE] = pa_memblock_ref(b); -+ cache->blocks[PA_SAMPLE_S24_32LE] = pa_memblock_ref(b); -+ cache->blocks[PA_SAMPLE_S24_32BE] = pa_memblock_ref(b); - cache->blocks[PA_SAMPLE_FLOAT32LE] = pa_memblock_ref(b); - cache->blocks[PA_SAMPLE_FLOAT32BE] = pa_memblock_ref(b); - break; -From 100af7efac584be9f229f4daf663dbb939f5d929 Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Fri, 1 May 2009 04:22:08 +0200 -Subject: [PATCH 21/28] sconv: fix a few minor conversion issues - ---- - src/pulsecore/sconv-s16le.c | 10 +++++----- - src/pulsecore/sconv.c | 2 +- - 2 files changed, 6 insertions(+), 6 deletions(-) - -diff --git src/pulsecore/sconv-s16le.c src/pulsecore/sconv-s16le.c -index 307ce7b..43b8cb3 100644 ---- src/pulsecore/sconv-s16le.c -+++ src/pulsecore/sconv-s16le.c -@@ -370,7 +370,7 @@ void pa_sconv_s24_32le_to_s16ne(unsigned n, const uint32_t *a, int16_t *b) { - pa_assert(b); - - for (; n > 0; n--) { -- *b = (int16_t) ((int32_t) (UINT32_FROM(*a) << 8) >> 16); -+ *b = (int16_t) (((int32_t) (UINT32_FROM(*a) << 8)) >> 16); - a++; - b++; - } -@@ -416,8 +416,8 @@ void pa_sconv_s24_32le_to_float32ne(unsigned n, const uint32_t *a, float *b) { - pa_assert(b); - - for (; n > 0; n--) { -- int32_t s = (int16_t) ((int32_t) (UINT32_FROM(*a) << 8)); -- *b = ((float) s) / 0x7FFFFFFF; -+ int32_t s = (int32_t) (UINT32_FROM(*a) << 8); -+ *b = (float) s / (float) 0x7FFFFFFF; - a ++; - b ++; - } -@@ -428,8 +428,8 @@ void pa_sconv_s24_32le_to_float32re(unsigned n, const uint32_t *a, float *b) { - pa_assert(b); - - for (; n > 0; n--) { -- int32_t s = (int16_t) ((int32_t) (UINT32_FROM(*a) << 8)); -- float k = ((float) s) / 0x7FFFFFFF; -+ int32_t s = (int32_t) (UINT32_FROM(*a) << 8); -+ float k = (float) s / (float) 0x7FFFFFFF; - *b = PA_FLOAT32_SWAP(k); - a ++; - b ++; -diff --git src/pulsecore/sconv.c src/pulsecore/sconv.c -index 29a9a45..d89f428 100644 ---- src/pulsecore/sconv.c -+++ src/pulsecore/sconv.c -@@ -75,7 +75,7 @@ static void u8_from_s16ne(unsigned n, const int16_t *a, uint8_t *b) { - pa_assert(b); - - for (; n > 0; n--, a++, b++) -- *b = (uint8_t) (*a / 0x100 + 0x80); -+ *b = (uint8_t) ((uint16_t) *a >> 8) + (uint8_t) 0x80U; - } - - /* float32 */ -From 1ab53c43c17943d49fc80c86ef2b513354eddc63 Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Thu, 14 May 2009 03:52:13 +0200 -Subject: [PATCH 23/28] rescue: make we don't end up in an endless loop when we can't move a sink input - ---- - src/modules/module-rescue-streams.c | 38 +++++++++++++++++++--------------- - 1 files changed, 21 insertions(+), 17 deletions(-) - -diff --git src/modules/module-rescue-streams.c src/modules/module-rescue-streams.c -index 7c99a9b..c22711a 100644 ---- src/modules/module-rescue-streams.c -+++ src/modules/module-rescue-streams.c -@@ -31,6 +31,7 @@ - #include <pulsecore/modargs.h> - #include <pulsecore/log.h> - #include <pulsecore/namereg.h> -+#include <pulsecore/core-util.h> - - #include "module-rescue-streams-symdef.h" - -@@ -49,6 +50,7 @@ struct userdata { - - static pa_hook_result_t sink_hook_callback(pa_core *c, pa_sink *sink, void* userdata) { - pa_sink_input *i; -+ uint32_t idx; - pa_sink *target; - - pa_assert(c); -@@ -58,15 +60,14 @@ static pa_hook_result_t sink_hook_callback(pa_core *c, pa_sink *sink, void* user - if (c->state == PA_CORE_SHUTDOWN) - return PA_HOOK_OK; - -- if (!pa_idxset_size(sink->inputs)) { -+ if (pa_idxset_size(sink->inputs) <= 0) { - pa_log_debug("No sink inputs to move away."); - return PA_HOOK_OK; - } - - if (!(target = pa_namereg_get(c, NULL, PA_NAMEREG_SINK)) || target == sink) { -- uint32_t idx; - -- for (target = pa_idxset_first(c->sinks, &idx); target; target = pa_idxset_next(c->sinks, &idx)) -+ PA_IDXSET_FOREACH(target, c->sinks, idx) - if (target != sink) - break; - -@@ -76,20 +77,24 @@ static pa_hook_result_t sink_hook_callback(pa_core *c, pa_sink *sink, void* user - } - } - -- while ((i = pa_idxset_first(sink->inputs, NULL))) { -+ pa_assert(target != sink); -+ -+ PA_IDXSET_FOREACH(i, sink->inputs, idx) { - if (pa_sink_input_move_to(i, target, FALSE) < 0) -- pa_log_warn("Failed to move sink input %u \"%s\" to %s.", i->index, pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME), target->name); -+ pa_log_info("Failed to move sink input %u \"%s\" to %s.", i->index, -+ pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), target->name); - else -- pa_log_info("Sucessfully moved sink input %u \"%s\" to %s.", i->index, pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME), target->name); -+ pa_log_info("Sucessfully moved sink input %u \"%s\" to %s.", i->index, -+ pa_strnull(pa_proplist_gets(i->proplist, PA_PROP_APPLICATION_NAME)), target->name); - } - -- - return PA_HOOK_OK; - } - - static pa_hook_result_t source_hook_callback(pa_core *c, pa_source *source, void* userdata) { - pa_source_output *o; - pa_source *target; -+ uint32_t idx; - - pa_assert(c); - pa_assert(source); -@@ -98,15 +103,14 @@ static pa_hook_result_t source_hook_callback(pa_core *c, pa_source *source, void - if (c->state == PA_CORE_SHUTDOWN) - return PA_HOOK_OK; - -- if (!pa_idxset_size(source->outputs)) { -+ if (pa_idxset_size(source->outputs) <= 0) { - pa_log_debug("No source outputs to move away."); - return PA_HOOK_OK; - } - - if (!(target = pa_namereg_get(c, NULL, PA_NAMEREG_SOURCE)) || target == source) { -- uint32_t idx; - -- for (target = pa_idxset_first(c->sources, &idx); target; target = pa_idxset_next(c->sources, &idx)) -+ PA_IDXSET_FOREACH(target, c->sources, idx) - if (target != source && !target->monitor_of == !source->monitor_of) - break; - -@@ -118,19 +122,20 @@ static pa_hook_result_t source_hook_callback(pa_core *c, pa_source *source, void - - pa_assert(target != source); - -- while ((o = pa_idxset_first(source->outputs, NULL))) { -+ PA_IDXSET_FOREACH(o, source->outputs, idx) { - if (pa_source_output_move_to(o, target, FALSE) < 0) -- pa_log_warn("Failed to move source output %u \"%s\" to %s.", o->index, pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME), target->name); -+ pa_log_info("Failed to move source output %u \"%s\" to %s.", o->index, -+ pa_strnull(pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME)), target->name); - else -- pa_log_info("Sucessfully moved source output %u \"%s\" to %s.", o->index, pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME), target->name); -+ pa_log_info("Sucessfully moved source output %u \"%s\" to %s.", o->index, -+ pa_strnull(pa_proplist_gets(o->proplist, PA_PROP_APPLICATION_NAME)), target->name); - } - -- - return PA_HOOK_OK; - } - - int pa__init(pa_module*m) { -- pa_modargs *ma = NULL; -+ pa_modargs *ma; - struct userdata *u; - - pa_assert(m); -@@ -153,10 +158,9 @@ void pa__done(pa_module*m) { - - pa_assert(m); - -- if (!m->userdata) -+ if (!(u = m->userdata)) - return; - -- u = m->userdata; - if (u->sink_slot) - pa_hook_slot_free(u->sink_slot); - if (u->source_slot) -From c41d9c71667de6d6e9aab077ac58b7371594bbef Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Fri, 8 May 2009 01:56:21 +0200 -Subject: [PATCH 24/28] core: introduce pa_{sink,source}_set_fixed_latency() - -This allows us to forward the fixed latency directly from the sink to -the monitor source withut having to wait for pa_sink_put(). ---- - src/modules/alsa/alsa-sink.c | 4 ++-- - src/modules/alsa/alsa-source.c | 4 ++-- - src/modules/bluetooth/module-bluetooth-device.c | 12 ++++++------ - src/modules/module-pipe-sink.c | 2 +- - src/modules/module-pipe-source.c | 2 +- - src/modules/module-sine-source.c | 3 +-- - src/modules/oss/module-oss.c | 4 ++-- - src/pulsecore/sink.c | 16 ++++++++++++++++ - src/pulsecore/sink.h | 1 + - src/pulsecore/source.c | 15 +++++++++++++++ - src/pulsecore/source.h | 1 + - 11 files changed, 48 insertions(+), 16 deletions(-) - -diff --git src/modules/alsa/alsa-sink.c src/modules/alsa/alsa-sink.c -index a544b58..94e15df 100644 ---- src/modules/alsa/alsa-sink.c -+++ src/modules/alsa/alsa-sink.c -@@ -473,7 +473,7 @@ static int mmap_write(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polle - u->since_start += frames * u->frame_size; - - #ifdef DEBUG_TIMING -- pa_log_debug("Wrote %lu bytes", (unsigned long) (frames * u->frame_size)); -+ pa_log_debug("Wrote %lu bytes (of possible %lu bytes)", (unsigned long) (frames * u->frame_size), (unsigned long) n_bytes); - #endif - - if ((size_t) frames * u->frame_size >= n_bytes) -@@ -1730,7 +1730,7 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca - pa_log_info("Time scheduling watermark is %0.2fms", - (double) pa_bytes_to_usec(u->tsched_watermark, &ss) / PA_USEC_PER_MSEC); - } else -- u->sink->fixed_latency = pa_bytes_to_usec(u->hwbuf_size, &ss); -+ pa_sink_set_fixed_latency(u->sink, pa_bytes_to_usec(u->hwbuf_size, &ss)); - - reserve_update(u); - -diff --git src/modules/alsa/alsa-source.c src/modules/alsa/alsa-source.c -index 5d8e349..c2f905a 100644 ---- src/modules/alsa/alsa-source.c -+++ src/modules/alsa/alsa-source.c -@@ -455,7 +455,7 @@ static int mmap_read(struct userdata *u, pa_usec_t *sleep_usec, pa_bool_t polled - u->read_count += frames * u->frame_size; - - #ifdef DEBUG_TIMING -- pa_log_debug("Read %lu bytes", (unsigned long) (frames * u->frame_size)); -+ pa_log_debug("Read %lu bytes (of possible %lu bytes)", (unsigned long) (frames * u->frame_size), (unsigned long) n_bytes); - #endif - - if ((size_t) frames * u->frame_size >= n_bytes) -@@ -1582,7 +1582,7 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p - pa_log_info("Time scheduling watermark is %0.2fms", - (double) pa_bytes_to_usec(u->tsched_watermark, &ss) / PA_USEC_PER_MSEC); - } else -- u->source->fixed_latency = pa_bytes_to_usec(u->hwbuf_size, &ss); -+ pa_source_set_fixed_latency(u->source, pa_bytes_to_usec(u->hwbuf_size, &ss)); - - reserve_update(u); - -diff --git src/modules/bluetooth/module-bluetooth-device.c src/modules/bluetooth/module-bluetooth-device.c -index 90f6486..3465b80 100644 ---- src/modules/bluetooth/module-bluetooth-device.c -+++ src/modules/bluetooth/module-bluetooth-device.c -@@ -1608,9 +1608,9 @@ static int add_sink(struct userdata *u) { - u->sink->parent.process_msg = sink_process_msg; - - pa_sink_set_max_request(u->sink, u->block_size); -- u->sink->fixed_latency = -- (u->profile == PROFILE_A2DP ? FIXED_LATENCY_PLAYBACK_A2DP : FIXED_LATENCY_PLAYBACK_HSP) + -- pa_bytes_to_usec(u->block_size, &u->sample_spec); -+ pa_sink_set_fixed_latency(u->sink, -+ (u->profile == PROFILE_A2DP ? FIXED_LATENCY_PLAYBACK_A2DP : FIXED_LATENCY_PLAYBACK_HSP) + -+ pa_bytes_to_usec(u->block_size, &u->sample_spec)); - } - - if (u->profile == PROFILE_HSP) { -@@ -1659,9 +1659,9 @@ static int add_source(struct userdata *u) { - u->source->userdata = u; - u->source->parent.process_msg = source_process_msg; - -- u->source->fixed_latency = -- (/* u->profile == PROFILE_A2DP ? FIXED_LATENCY_RECORD_A2DP : */ FIXED_LATENCY_RECORD_HSP) + -- pa_bytes_to_usec(u->block_size, &u->sample_spec); -+ pa_source_set_fixed_latency(u->source, -+ (/* u->profile == PROFILE_A2DP ? FIXED_LATENCY_RECORD_A2DP : */ FIXED_LATENCY_RECORD_HSP) + -+ pa_bytes_to_usec(u->block_size, &u->sample_spec)); - } - - if (u->profile == PROFILE_HSP) { -diff --git src/modules/module-pipe-sink.c src/modules/module-pipe-sink.c -index 9d3e55d..304d01c 100644 ---- src/modules/module-pipe-sink.c -+++ src/modules/module-pipe-sink.c -@@ -293,7 +293,7 @@ int pa__init(pa_module*m) { - pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq); - pa_sink_set_rtpoll(u->sink, u->rtpoll); - pa_sink_set_max_request(u->sink, PIPE_BUF); -- u->sink->fixed_latency = pa_bytes_to_usec(PIPE_BUF, &u->sink->sample_spec); -+ pa_sink_set_fixed_latency(u->sink, pa_bytes_to_usec(PIPE_BUF, &u->sink->sample_spec)); - - u->rtpoll_item = pa_rtpoll_item_new(u->rtpoll, PA_RTPOLL_NEVER, 1); - pollfd = pa_rtpoll_item_get_pollfd(u->rtpoll_item, NULL); -diff --git src/modules/module-pipe-source.c src/modules/module-pipe-source.c -index df72d79..6ed4fbf 100644 ---- src/modules/module-pipe-source.c -+++ src/modules/module-pipe-source.c -@@ -277,7 +277,7 @@ int pa__init(pa_module*m) { - - pa_source_set_asyncmsgq(u->source, u->thread_mq.inq); - pa_source_set_rtpoll(u->source, u->rtpoll); -- u->source->fixed_latency = pa_bytes_to_usec(PIPE_BUF, &u->source->sample_spec); -+ pa_source_set_fixed_latency(u->source, pa_bytes_to_usec(PIPE_BUF, &u->source->sample_spec)); - - u->rtpoll_item = pa_rtpoll_item_new(u->rtpoll, PA_RTPOLL_NEVER, 1); - pollfd = pa_rtpoll_item_get_pollfd(u->rtpoll_item, NULL); -diff --git src/modules/module-sine-source.c src/modules/module-sine-source.c -index a5f1ce7..a6e15d8 100644 ---- src/modules/module-sine-source.c -+++ src/modules/module-sine-source.c -@@ -264,8 +264,7 @@ int pa__init(pa_module*m) { - - pa_source_set_asyncmsgq(u->source, u->thread_mq.inq); - pa_source_set_rtpoll(u->source, u->rtpoll); -- u->source->fixed_latency = u->block_usec; -- -+ pa_source_set_fixed_latency(u->source, u->block_usec); - - if (!(u->thread = pa_thread_new(thread_func, u))) { - pa_log("Failed to create thread."); -diff --git src/modules/oss/module-oss.c src/modules/oss/module-oss.c -index aa5f918..d6f549c 100644 ---- src/modules/oss/module-oss.c -+++ src/modules/oss/module-oss.c -@@ -1328,8 +1328,8 @@ int pa__init(pa_module*m) { - - pa_source_set_asyncmsgq(u->source, u->thread_mq.inq); - pa_source_set_rtpoll(u->source, u->rtpoll); -+ pa_source_set_fixed_latency(u->source, pa_bytes_to_usec(u->in_hwbuf_size, &u->source->sample_spec)); - u->source->refresh_volume = TRUE; -- u->source->fixed_latency = pa_bytes_to_usec(u->in_hwbuf_size, &u->source->sample_spec); - - if (use_mmap) - u->in_mmap_memblocks = pa_xnew0(pa_memblock*, u->in_nfrags); -@@ -1390,8 +1390,8 @@ int pa__init(pa_module*m) { - - pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq); - pa_sink_set_rtpoll(u->sink, u->rtpoll); -+ pa_sink_set_fixed_latency(u->sink, pa_bytes_to_usec(u->out_hwbuf_size, &u->sink->sample_spec)); - u->sink->refresh_volume = TRUE; -- u->sink->fixed_latency = pa_bytes_to_usec(u->out_hwbuf_size, &u->sink->sample_spec); - - pa_sink_set_max_request(u->sink, u->out_hwbuf_size); - -diff --git src/pulsecore/sink.c src/pulsecore/sink.c -index c99f9a8..2225886 100644 ---- src/pulsecore/sink.c -+++ src/pulsecore/sink.c -@@ -2054,6 +2054,22 @@ void pa_sink_set_latency_range_within_thread(pa_sink *s, pa_usec_t min_latency, - pa_source_set_latency_range_within_thread(s->monitor_source, min_latency, max_latency); - } - -+/* Called from main thread, before the sink is put */ -+void pa_sink_set_fixed_latency(pa_sink *s, pa_usec_t latency) { -+ pa_sink_assert_ref(s); -+ -+ pa_assert(pa_sink_get_state(s) == PA_SINK_INIT); -+ -+ if (latency < ABSOLUTE_MIN_LATENCY) -+ latency = ABSOLUTE_MIN_LATENCY; -+ -+ if (latency > ABSOLUTE_MAX_LATENCY) -+ latency = ABSOLUTE_MAX_LATENCY; -+ -+ s->fixed_latency = latency; -+ pa_source_set_fixed_latency(s->monitor_source, latency); -+} -+ - /* Called from main context */ - size_t pa_sink_get_max_rewind(pa_sink *s) { - size_t r; -diff --git src/pulsecore/sink.h src/pulsecore/sink.h -index 352282b..e33b3cf 100644 ---- src/pulsecore/sink.h -+++ src/pulsecore/sink.h -@@ -229,6 +229,7 @@ void pa_sink_set_rtpoll(pa_sink *s, pa_rtpoll *p); - void pa_sink_set_max_rewind(pa_sink *s, size_t max_rewind); - void pa_sink_set_max_request(pa_sink *s, size_t max_request); - void pa_sink_set_latency_range(pa_sink *s, pa_usec_t min_latency, pa_usec_t max_latency); -+void pa_sink_set_fixed_latency(pa_sink *s, pa_usec_t latency); - - void pa_sink_detach(pa_sink *s); - void pa_sink_attach(pa_sink *s); -diff --git src/pulsecore/source.c src/pulsecore/source.c -index 0baaed1..e8deaf7 100644 ---- src/pulsecore/source.c -+++ src/pulsecore/source.c -@@ -1280,6 +1280,21 @@ void pa_source_set_latency_range_within_thread(pa_source *s, pa_usec_t min_laten - pa_source_invalidate_requested_latency(s); - } - -+/* Called from main thread, before the source is put */ -+void pa_source_set_fixed_latency(pa_source *s, pa_usec_t latency) { -+ pa_source_assert_ref(s); -+ -+ pa_assert(pa_source_get_state(s) == PA_SOURCE_INIT); -+ -+ if (latency < ABSOLUTE_MIN_LATENCY) -+ latency = ABSOLUTE_MIN_LATENCY; -+ -+ if (latency > ABSOLUTE_MAX_LATENCY) -+ latency = ABSOLUTE_MAX_LATENCY; -+ -+ s->fixed_latency = latency; -+} -+ - /* Called from main thread */ - size_t pa_source_get_max_rewind(pa_source *s) { - size_t r; -diff --git src/pulsecore/source.h src/pulsecore/source.h -index b502c22..2978f57 100644 ---- src/pulsecore/source.h -+++ src/pulsecore/source.h -@@ -210,6 +210,7 @@ void pa_source_set_rtpoll(pa_source *s, pa_rtpoll *p); - - void pa_source_set_max_rewind(pa_source *s, size_t max_rewind); - void pa_source_set_latency_range(pa_source *s, pa_usec_t min_latency, pa_usec_t max_latency); -+void pa_source_set_fixed_latency(pa_source *s, pa_usec_t latency); - - void pa_source_detach(pa_source *s); - void pa_source_attach(pa_source *s); -From c73733777f11080373264ed4e992c6860809898e Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Fri, 8 May 2009 02:02:36 +0200 -Subject: [PATCH 25/28] core: cache requested latency only when we are running, not while we are still constructing - ---- - src/pulsecore/sink.c | 7 +++++-- - src/pulsecore/source.c | 7 +++++-- - 2 files changed, 10 insertions(+), 4 deletions(-) - -diff --git src/pulsecore/sink.c src/pulsecore/sink.c -index 2225886..161b7c9 100644 ---- src/pulsecore/sink.c -+++ src/pulsecore/sink.c -@@ -1867,8 +1867,11 @@ pa_usec_t pa_sink_get_requested_latency_within_thread(pa_sink *s) { - if (result != (pa_usec_t) -1) - result = PA_CLAMP(result, s->thread_info.min_latency, s->thread_info.max_latency); - -- s->thread_info.requested_latency = result; -- s->thread_info.requested_latency_valid = TRUE; -+ if (PA_SINK_IS_LINKED(s->thread_info.state)) { -+ /* Only cache if properly initialized */ -+ s->thread_info.requested_latency = result; -+ s->thread_info.requested_latency_valid = TRUE; -+ } - - return result; - } -diff --git src/pulsecore/source.c src/pulsecore/source.c -index e8deaf7..8a4c8c4 100644 ---- src/pulsecore/source.c -+++ src/pulsecore/source.c -@@ -1122,8 +1122,11 @@ pa_usec_t pa_source_get_requested_latency_within_thread(pa_source *s) { - if (result != (pa_usec_t) -1) - result = PA_CLAMP(result, s->thread_info.min_latency, s->thread_info.max_latency); - -- s->thread_info.requested_latency = result; -- s->thread_info.requested_latency_valid = TRUE; -+ if (PA_SOURCE_IS_LINKED(s->thread_info.state)) { -+ /* Only cache this if we are fully set up */ -+ s->thread_info.requested_latency = result; -+ s->thread_info.requested_latency_valid = TRUE; -+ } - - return result; - } -From 85fb360fe3b9d3b3fb4e537373f4dc9202ca5e13 Mon Sep 17 00:00:00 2001 -From: Lennart Poettering <lennart@poettering.net> -Date: Mon, 8 Jun 2009 18:22:19 +0200 -Subject: [PATCH 26/28] sample: fix build on BE archs - ---- - src/pulsecore/sample-util.c | 2 +- - 1 files changed, 1 insertions(+), 1 deletions(-) - -diff --git src/pulsecore/sample-util.c src/pulsecore/sample-util.c -index dda3883..5b8ccf5 100644 ---- src/pulsecore/sample-util.c -+++ src/pulsecore/sample-util.c -@@ -1182,7 +1182,7 @@ pa_memchunk* pa_silence_memchunk_get(pa_silence_cache *cache, pa_mempool *pool, - case PA_SAMPLE_S24LE: - case PA_SAMPLE_S24BE: - case PA_SAMPLE_S24_32LE: -- case PA_SAMPLE_S24_32RE: -+ case PA_SAMPLE_S24_32BE: - case PA_SAMPLE_FLOAT32LE: - case PA_SAMPLE_FLOAT32BE: - cache->blocks[PA_SAMPLE_S16LE] = b = silence_memblock_new(pool, 0); -Index: pulseaudio-0.9.14/src/daemon/daemon.conf.in -=================================================================== ---- src/daemon/daemon.conf.in 2009-03-07 05:01:11.000000000 -0500 -+++ src/daemon/daemon.conf.in 2009-03-07 05:01:54.000000000 -0500 -@@ -46,7 +46,7 @@ - ; log-target = auto - ; log-level = notice - --; resample-method = speex-float-3 -+resample-method = speex-float-1 - ; disable-remixing = no - ; disable-lfe-remixing = yes - -@@ -72,5 +72,5 @@ - ; default-sample-rate = 44100 - ; default-sample-channels = 2 - --; default-fragments = 4 --; default-fragment-size-msec = 25 -+default-fragments = 8 -+default-fragment-size-msec = 10 diff --git a/audio/pulseaudio/pkg-message b/audio/pulseaudio/pkg-message deleted file mode 100644 index 83439b120f72..000000000000 --- a/audio/pulseaudio/pkg-message +++ /dev/null @@ -1,6 +0,0 @@ -===> -Pulseaudio is designed to run in realtime, to achieve this pulseaudio is -marked SUID root by default. To take advantage of pulseaudio's realtime -functionality you must be a member of the 'pulse-rt' group. - -ie: 'pw mod group pulse-rt -m [USERNAME]' diff --git a/audio/pulseaudio/pkg-plist b/audio/pulseaudio/pkg-plist index e6c39d46b70f..81809d17dc68 100644 --- a/audio/pulseaudio/pkg-plist +++ b/audio/pulseaudio/pkg-plist @@ -4,12 +4,15 @@ bin/pacat bin/pacmd bin/pactl bin/padsp +bin/pamon bin/paplay bin/parec +bin/parecord bin/pasuspender bin/pax11publish bin/pulseaudio bin/start-pulseaudio-x11 +etc/dbus-1/system.d/pulseaudio-system.conf @unexec if cmp -s %D/etc/pulse/client.conf %D/etc/pulse/client.conf-dist; then rm -f %D/etc/pulse/client.conf; fi etc/pulse/client.conf-dist @exec [ -f %B/client.conf ] || cp %B/%f %B/client.conf @@ -39,6 +42,7 @@ include/pulse/mainloop.h include/pulse/operation.h include/pulse/proplist.h include/pulse/pulseaudio.h +include/pulse/rtclock.h include/pulse/sample.h include/pulse/scache.h include/pulse/simple.h @@ -137,12 +141,16 @@ lib/pulse-%%PULSE_VERSION%%/modules/module-http-protocol-tcp.a lib/pulse-%%PULSE_VERSION%%/modules/module-http-protocol-tcp.so lib/pulse-%%PULSE_VERSION%%/modules/module-http-protocol-unix.a lib/pulse-%%PULSE_VERSION%%/modules/module-http-protocol-unix.so +lib/pulse-%%PULSE_VERSION%%/modules/module-intended-roles.a +lib/pulse-%%PULSE_VERSION%%/modules/module-intended-roles.so %%JACK%%lib/pulse-%%PULSE_VERSION%%/modules/module-jack-sink.a %%JACK%%lib/pulse-%%PULSE_VERSION%%/modules/module-jack-sink.so %%JACK%%lib/pulse-%%PULSE_VERSION%%/modules/module-jack-source.a %%JACK%%lib/pulse-%%PULSE_VERSION%%/modules/module-jack-source.so lib/pulse-%%PULSE_VERSION%%/modules/module-ladspa-sink.a lib/pulse-%%PULSE_VERSION%%/modules/module-ladspa-sink.so +lib/pulse-%%PULSE_VERSION%%/modules/module-loopback.a +lib/pulse-%%PULSE_VERSION%%/modules/module-loopback.so lib/pulse-%%PULSE_VERSION%%/modules/module-match.a lib/pulse-%%PULSE_VERSION%%/modules/module-match.so lib/pulse-%%PULSE_VERSION%%/modules/module-native-protocol-fd.a @@ -173,6 +181,8 @@ lib/pulse-%%PULSE_VERSION%%/modules/module-rtp-recv.a lib/pulse-%%PULSE_VERSION%%/modules/module-rtp-recv.so lib/pulse-%%PULSE_VERSION%%/modules/module-rtp-send.a lib/pulse-%%PULSE_VERSION%%/modules/module-rtp-send.so +lib/pulse-%%PULSE_VERSION%%/modules/module-rygel-media-server.a +lib/pulse-%%PULSE_VERSION%%/modules/module-rygel-media-server.so lib/pulse-%%PULSE_VERSION%%/modules/module-simple-protocol-tcp.a lib/pulse-%%PULSE_VERSION%%/modules/module-simple-protocol-tcp.so lib/pulse-%%PULSE_VERSION%%/modules/module-simple-protocol-unix.a @@ -208,30 +218,35 @@ libdata/pkgconfig/libpulse-mainloop-glib.pc libdata/pkgconfig/libpulse-simple.pc libdata/pkgconfig/libpulse.pc %%GCONF%%libexec/pulse/gconf-helper -%%HAL%%share/PolicyKit/policy/org.pulseaudio.policy share/locale/as/LC_MESSAGES/pulseaudio.mo share/locale/bn_IN/LC_MESSAGES/pulseaudio.mo share/locale/ca/LC_MESSAGES/pulseaudio.mo share/locale/cs/LC_MESSAGES/pulseaudio.mo share/locale/de/LC_MESSAGES/pulseaudio.mo +share/locale/de_CH/LC_MESSAGES/pulseaudio.mo share/locale/el/LC_MESSAGES/pulseaudio.mo share/locale/es/LC_MESSAGES/pulseaudio.mo share/locale/fi/LC_MESSAGES/pulseaudio.mo share/locale/fr/LC_MESSAGES/pulseaudio.mo share/locale/gu/LC_MESSAGES/pulseaudio.mo +share/locale/hi/LC_MESSAGES/pulseaudio.mo share/locale/it/LC_MESSAGES/pulseaudio.mo +share/locale/ja/LC_MESSAGES/pulseaudio.mo share/locale/kn/LC_MESSAGES/pulseaudio.mo +share/locale/ml/LC_MESSAGES/pulseaudio.mo share/locale/mr/LC_MESSAGES/pulseaudio.mo share/locale/nl/LC_MESSAGES/pulseaudio.mo share/locale/or/LC_MESSAGES/pulseaudio.mo share/locale/pa/LC_MESSAGES/pulseaudio.mo share/locale/pl/LC_MESSAGES/pulseaudio.mo +share/locale/pt/LC_MESSAGES/pulseaudio.mo share/locale/pt_BR/LC_MESSAGES/pulseaudio.mo share/locale/sr/LC_MESSAGES/pulseaudio.mo share/locale/sr@latin/LC_MESSAGES/pulseaudio.mo share/locale/sv/LC_MESSAGES/pulseaudio.mo share/locale/ta/LC_MESSAGES/pulseaudio.mo share/locale/te/LC_MESSAGES/pulseaudio.mo +share/locale/uk/LC_MESSAGES/pulseaudio.mo share/locale/zh_CN/LC_MESSAGES/pulseaudio.mo %%GCONF%%@dirrm libexec/pulse @dirrm lib/pulse-%%PULSE_VERSION%%/modules @@ -242,6 +257,8 @@ share/locale/zh_CN/LC_MESSAGES/pulseaudio.mo @dirrmtry share/locale/sr@latin @dirrmtry share/locale/mr/LC_MESSAGES @dirrmtry share/locale/mr +@dirrmtry share/locale/de_CH/LC_MESSAGES +@dirrmtry share/locale/de_CH @dirrmtry share/locale/bn_IN/LC_MESSAGES @dirrmtry share/locale/bn_IN @dirrmtry share/locale/as/LC_MESSAGES |