[pulseaudio] 01/01: Swap pa_yes_no patch for upstream patch fixing the same issue
Felipe Sateler
fsateler at moszumanska.debian.org
Mon Apr 27 14:51:53 UTC 2015
This is an automated email from the git hooks/post-receive script.
fsateler pushed a commit to branch fsateler-ubuntu
in repository pulseaudio.
commit 94f9a34f7c943c97dca3d79d4fc7caa1bfef2a84
Author: Felipe Sateler <fsateler at debian.org>
Date: Tue Apr 21 21:12:25 2015 -0300
Swap pa_yes_no patch for upstream patch fixing the same issue
Almost a cherry-pick of f5cb978
Pick upstream patch that creates a localised version of pa_yes_no
* Pick upstream patch that creates a localised version of pa_yes_no
- This fixes a problem when that function was used to create module
loading arguments.
Conflicts:
debian/patches/series
---
...actl-Make-one-localised-and-one-non-local.patch | 108 +++++++++++++++++++++
debian/patches/0099-pa_yes_no.patch | 17 ----
debian/patches/series | 2 +-
3 files changed, 109 insertions(+), 18 deletions(-)
diff --git a/debian/patches/0099-core-util-pactl-Make-one-localised-and-one-non-local.patch b/debian/patches/0099-core-util-pactl-Make-one-localised-and-one-non-local.patch
new file mode 100644
index 0000000..8ba276c
--- /dev/null
+++ b/debian/patches/0099-core-util-pactl-Make-one-localised-and-one-non-local.patch
@@ -0,0 +1,108 @@
+From 17e939dc155a73727ec92cde3de62d4fe0ed4eaa Mon Sep 17 00:00:00 2001
+From: David Henningsson <david.henningsson at canonical.com>
+Date: Mon, 20 Apr 2015 17:36:53 +0200
+Subject: [PATCH] core-util, pactl: Make one localised and one non-localised
+ version of pa_yes_no
+
+We currently use pa_yes_no to write module arguments, so they can not be
+localised. Instead add a new pa_yes_no_localised function and use it in pactl
+(and thus, revert all other places to use the non-localised version).
+
+BugLink: https://bugs.launchpad.net/ubuntu/+source/pulseaudio/+bug/1445358
+Signed-off-by: David Henningsson <david.henningsson at canonical.com>
+---
+ src/pulsecore/core-util.h | 4 ++++
+ src/utils/pactl.c | 20 ++++++++++----------
+ 2 files changed, 14 insertions(+), 10 deletions(-)
+
+diff --git a/src/pulsecore/core-util.h b/src/pulsecore/core-util.h
+index dcdc40e..d5a2d39 100644
+--- a/src/pulsecore/core-util.h
++++ b/src/pulsecore/core-util.h
+@@ -90,6 +90,10 @@ int pa_parse_boolean(const char *s) PA_GCC_PURE;
+ int pa_parse_volume(const char *s, pa_volume_t *volume);
+
+ static inline const char *pa_yes_no(bool b) {
++ return b ? "yes" : "no";
++}
++
++static inline const char *pa_yes_no_localised(bool b) {
+ return b ? _("yes") : _("no");
+ }
+
+diff --git a/src/utils/pactl.c b/src/utils/pactl.c
+index a13c7fb..d6791d4 100644
+--- a/src/utils/pactl.c
++++ b/src/utils/pactl.c
+@@ -196,7 +196,7 @@ static void get_server_info_callback(pa_context *c, const pa_server_info *i, voi
+ pa_context_get_server(c),
+ pa_context_get_protocol_version(c),
+ pa_context_get_server_protocol_version(c),
+- pa_yes_no(pa_context_is_local(c)),
++ pa_yes_no_localised(pa_context_is_local(c)),
+ pa_context_get_index(c),
+ pa_context_get_tile_size(c, NULL));
+
+@@ -302,7 +302,7 @@ static void get_sink_info_callback(pa_context *c, const pa_sink_info *i, int is_
+ pa_sample_spec_snprint(s, sizeof(s), &i->sample_spec),
+ pa_channel_map_snprint(cm, sizeof(cm), &i->channel_map),
+ i->owner_module,
+- pa_yes_no(i->mute),
++ pa_yes_no_localised(i->mute),
+ pa_cvolume_snprint_verbose(cv, sizeof(cv), &i->volume, &i->channel_map, i->flags & PA_SINK_DECIBEL_VOLUME),
+ pa_cvolume_get_balance(&i->volume, &i->channel_map),
+ pa_volume_snprint_verbose(v, sizeof(v), i->base_volume, i->flags & PA_SINK_DECIBEL_VOLUME),
+@@ -409,7 +409,7 @@ static void get_source_info_callback(pa_context *c, const pa_source_info *i, int
+ pa_sample_spec_snprint(s, sizeof(s), &i->sample_spec),
+ pa_channel_map_snprint(cm, sizeof(cm), &i->channel_map),
+ i->owner_module,
+- pa_yes_no(i->mute),
++ pa_yes_no_localised(i->mute),
+ pa_cvolume_snprint_verbose(cv, sizeof(cv), &i->volume, &i->channel_map, i->flags & PA_SOURCE_DECIBEL_VOLUME),
+ pa_cvolume_get_balance(&i->volume, &i->channel_map),
+ pa_volume_snprint_verbose(v, sizeof(v), i->base_volume, i->flags & PA_SOURCE_DECIBEL_VOLUME),
+@@ -578,8 +578,8 @@ static void get_card_info_callback(pa_context *c, const pa_card_info *i, int is_
+
+ printf(_("\tProfiles:\n"));
+ for (p = i->profiles2; *p; p++)
+- printf("\t\t%s: %s (sinks: %u, sources: %u, priority: %u, available: %s)\n", (*p)->name,
+- (*p)->description, (*p)->n_sinks, (*p)->n_sources, (*p)->priority, pa_yes_no((*p)->available));
++ printf(_("\t\t%s: %s (sinks: %u, sources: %u, priority: %u, available: %s)\n"), (*p)->name,
++ (*p)->description, (*p)->n_sinks, (*p)->n_sources, (*p)->priority, pa_yes_no_localised((*p)->available));
+ }
+
+ if (i->active_profile)
+@@ -672,8 +672,8 @@ static void get_sink_input_info_callback(pa_context *c, const pa_sink_input_info
+ pa_sample_spec_snprint(s, sizeof(s), &i->sample_spec),
+ pa_channel_map_snprint(cm, sizeof(cm), &i->channel_map),
+ pa_format_info_snprint(f, sizeof(f), i->format),
+- pa_yes_no(i->corked),
+- pa_yes_no(i->mute),
++ pa_yes_no_localised(i->corked),
++ pa_yes_no_localised(i->mute),
+ pa_cvolume_snprint_verbose(cv, sizeof(cv), &i->volume, &i->channel_map, true),
+ pa_cvolume_get_balance(&i->volume, &i->channel_map),
+ (double) i->buffer_usec,
+@@ -742,8 +742,8 @@ static void get_source_output_info_callback(pa_context *c, const pa_source_outpu
+ pa_sample_spec_snprint(s, sizeof(s), &i->sample_spec),
+ pa_channel_map_snprint(cm, sizeof(cm), &i->channel_map),
+ pa_format_info_snprint(f, sizeof(f), i->format),
+- pa_yes_no(i->corked),
+- pa_yes_no(i->mute),
++ pa_yes_no_localised(i->corked),
++ pa_yes_no_localised(i->mute),
+ pa_cvolume_snprint_verbose(cv, sizeof(cv), &i->volume, &i->channel_map, true),
+ pa_cvolume_get_balance(&i->volume, &i->channel_map),
+ (double) i->buffer_usec,
+@@ -805,7 +805,7 @@ static void get_sample_info_callback(pa_context *c, const pa_sample_info *i, int
+ pa_cvolume_get_balance(&i->volume, &i->channel_map),
+ (double) i->duration/1000000.0,
+ t,
+- pa_yes_no(i->lazy),
++ pa_yes_no_localised(i->lazy),
+ i->filename ? i->filename : _("n/a"),
+ pl = pa_proplist_to_string_sep(i->proplist, "\n\t\t"));
+
+--
+2.1.4
+
diff --git a/debian/patches/0099-pa_yes_no.patch b/debian/patches/0099-pa_yes_no.patch
deleted file mode 100644
index ae07b22..0000000
--- a/debian/patches/0099-pa_yes_no.patch
+++ /dev/null
@@ -1,17 +0,0 @@
-Subject: Fix PulseAudio failure on some non-English locales
-Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/pulseaudio/+bug/1445358
-Author: Simos Xenitellis
-
-diff --git a/src/pulsecore/core-util.h b/src/pulsecore/core-util.h
-index dcdc40e..e6be901 100644
---- a/src/pulsecore/core-util.h
-+++ b/src/pulsecore/core-util.h
-@@ -90,7 +90,7 @@ int pa_parse_boolean(const char *s) PA_GCC_PURE;
- int pa_parse_volume(const char *s, pa_volume_t *volume);
-
- static inline const char *pa_yes_no(bool b) {
-- return b ? _("yes") : _("no");
-+ return b ? "yes" : "no";
- }
-
- static inline const char *pa_strnull(const char *x) {
diff --git a/debian/patches/series b/debian/patches/series
index bfd3520..692cc54 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -5,7 +5,7 @@
0016-nodisplay-autostart.patch
0022-inotify-wrapper-Quit-daemon-if-pid-file-is-removed.patch
0023-fixing_snd_mixer_poll_descriptors_count_when_zero.patch
-0099-pa_yes_no.patch
+0099-core-util-pactl-Make-one-localised-and-one-non-local.patch
# Ubuntu touch stuff
0202-dont-probe-ucm.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-pulseaudio/pulseaudio.git
More information about the pkg-pulseaudio-devel
mailing list