sink: pa_sink_reconfigure() returns 0 if incoming sample spec is same as sink's 87/189687/2 accepted/tizen/5.0/unified/20181102.030706 accepted/tizen/unified/20180921.042524 submit/tizen/20180920.045112 submit/tizen_5.0/20181101.000007
authorSangchul Lee <sc11.lee@samsung.com>
Thu, 20 Sep 2018 01:14:46 +0000 (10:14 +0900)
committerSangchul Lee <sc11.lee@samsung.com>
Thu, 20 Sep 2018 01:31:22 +0000 (10:31 +0900)
pa_sink_reconfigure() returned -1 if that case. But it seems a bit harsh
that this situation is considered as an error. Adding another return value
or just returning 0 can be an option. This is a temporary patch for tizen.

[Version] 11.1-50
[Issue Type] Enhancement

Change-Id: Ie11e4f9e4fa7d7b9d0ef03bb8e868de5c3e3d6dc
Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
packaging/pulseaudio.spec
src/pulsecore/sink.c

index 2e9f60b..6bd70cd 100644 (file)
@@ -3,7 +3,7 @@
 Name:             pulseaudio
 Summary:          Improved Linux sound server
 Version:          11.1
-Release:          49
+Release:          50
 Group:            Multimedia/Audio
 License:          LGPL-2.1
 URL:              http://pulseaudio.org
index 9aa2848..f67564b 100644 (file)
@@ -1645,7 +1645,14 @@ int pa_sink_reconfigure(pa_sink *s, pa_sample_spec *spec, bool passthrough) {
     }
 
     if (pa_sample_spec_equal(&desired_spec, &s->sample_spec) && passthrough == pa_sink_is_passthrough(s))
+#ifdef __TIZEN__
+    {
+        pa_log_info("desired spec is same as sink->sample_spec");
+        return 0;
+    }
+#else
         return -1;
+#endif
 
     if (!passthrough && pa_sink_used_by(s) > 0)
         return -1;