From 37c6f725e0505126545e006ae5f6deb7205a19c0 Mon Sep 17 00:00:00 2001 From: Seungbae Shin Date: Mon, 17 Sep 2018 17:20:41 +0900 Subject: [PATCH] Fix build warnings [Version] 11.1-47 [Issue Type] Build Change-Id: I964f7b7fdacd853614823687cc7576eafe7f18bf --- packaging/pulseaudio.spec | 2 +- src/modules/bluetooth/bluez5-util.c | 2 ++ src/modules/bluetooth/bluez5-util.h | 4 ++-- src/modules/bluetooth/module-bluez5-device.c | 19 ++++++++++++------- src/modules/module-loopback.c | 8 ++++++++ src/modules/raop/raop-client.c | 4 ++++ 6 files changed, 29 insertions(+), 10 deletions(-) diff --git a/packaging/pulseaudio.spec b/packaging/pulseaudio.spec index a8f7a26..ca027f9 100644 --- a/packaging/pulseaudio.spec +++ b/packaging/pulseaudio.spec @@ -3,7 +3,7 @@ Name: pulseaudio Summary: Improved Linux sound server Version: 11.1 -Release: 47 +Release: 48 Group: Multimedia/Audio License: LGPL-2.1 URL: http://pulseaudio.org diff --git a/src/modules/bluetooth/bluez5-util.c b/src/modules/bluetooth/bluez5-util.c index 5e352f6..0ec4ed9 100644 --- a/src/modules/bluetooth/bluez5-util.c +++ b/src/modules/bluetooth/bluez5-util.c @@ -1637,7 +1637,9 @@ static DBusMessage *endpoint_set_configuration(DBusConnection *conn, DBusMessage dbus_message_iter_get_basic(&value, &dev_path); } else if (pa_streq(key, "Configuration")) { DBusMessageIter array; +#ifndef BLUETOOTH_APTX_SUPPORT a2dp_sbc_t *c; +#endif if (var != DBUS_TYPE_ARRAY) { pa_log_error("Property %s of wrong type %c", key, (char)var); diff --git a/src/modules/bluetooth/bluez5-util.h b/src/modules/bluetooth/bluez5-util.h index 7f4f674..9b8ed9c 100644 --- a/src/modules/bluetooth/bluez5-util.h +++ b/src/modules/bluetooth/bluez5-util.h @@ -30,8 +30,8 @@ #define PA_BLUETOOTH_UUID_HFP_AG "0000111f-0000-1000-8000-00805f9b34fb" #ifdef __TIZEN_BT__ -#ifdef pa_log_debug(...) -#undef pa_log_debug(...) +#ifdef pa_log_debug +#undef pa_log_debug #define pa_log_debug(...) pa_log_level_meta(PA_LOG_INFO, __FILE__, __LINE__, __func__, __VA_ARGS__) #endif #endif diff --git a/src/modules/bluetooth/module-bluez5-device.c b/src/modules/bluetooth/module-bluez5-device.c index ba4f9d6..85a4755 100644 --- a/src/modules/bluetooth/module-bluez5-device.c +++ b/src/modules/bluetooth/module-bluez5-device.c @@ -27,10 +27,6 @@ #include #include -#ifdef BLUETOOTH_APTX_SUPPORT -#include -#endif - #include #include #include @@ -60,6 +56,10 @@ #include "module-bluez5-device-symdef.h" +#ifdef BLUETOOTH_APTX_SUPPORT +#include +#endif + PA_MODULE_AUTHOR("João Paulo Rechi Vita"); PA_MODULE_DESCRIPTION("BlueZ 5 Bluetooth audio sink and source"); PA_MODULE_VERSION(PACKAGE_VERSION); @@ -999,12 +999,20 @@ static void transport_config_mtu(struct userdata *u) { u->write_block_size = u->write_link_mtu; if (!pa_frame_aligned(u->read_block_size, &u->source->sample_spec)) { +#ifdef __TIZEN__ + pa_log_debug("Got invalid read MTU: %zu, rounding down", u->read_block_size); +#else pa_log_debug("Got invalid read MTU: %lu, rounding down", u->read_block_size); +#endif u->read_block_size = pa_frame_align(u->read_block_size, &u->source->sample_spec); } if (!pa_frame_aligned(u->write_block_size, &u->sink->sample_spec)) { +#ifdef __TIZEN__ + pa_log_debug("Got invalid write MTU: %zu, rounding down", u->write_block_size); +#else pa_log_debug("Got invalid write MTU: %lu, rounding down", u->write_block_size); +#endif u->write_block_size = pa_frame_align(u->write_block_size, &u->sink->sample_spec); } @@ -2275,9 +2283,6 @@ static int add_card(struct userdata *u) { pa_bluetooth_profile_t *p; const char *uuid; void *state; -#ifdef __TIZEN_BT__ - const char *default_profile; -#endif pa_assert(u); pa_assert(u->device); diff --git a/src/modules/module-loopback.c b/src/modules/module-loopback.c index ded59e1..e57df90 100644 --- a/src/modules/module-loopback.c +++ b/src/modules/module-loopback.c @@ -478,13 +478,21 @@ static void memblockq_adjust(struct userdata *u, pa_usec_t latency_offset_usec, if (current_memblockq_length > requested_memblockq_length) { /* Drop audio from queue */ buffer_correction = current_memblockq_length - requested_memblockq_length; +#ifdef __TIZEN__ + pa_log_info("Dropping %llu usec of audio from queue", pa_bytes_to_usec(buffer_correction, &u->sink_input->sample_spec)); +#else pa_log_info("Dropping %lu usec of audio from queue", pa_bytes_to_usec(buffer_correction, &u->sink_input->sample_spec)); +#endif pa_memblockq_drop(u->memblockq, buffer_correction); } else if (current_memblockq_length < requested_memblockq_length && allow_push) { /* Add silence to queue */ buffer_correction = requested_memblockq_length - current_memblockq_length; +#ifdef __TIZEN__ + pa_log_info("Adding %llu usec of silence to queue", pa_bytes_to_usec(buffer_correction, &u->sink_input->sample_spec)); +#else pa_log_info("Adding %lu usec of silence to queue", pa_bytes_to_usec(buffer_correction, &u->sink_input->sample_spec)); +#endif pa_memblockq_seek(u->memblockq, (int64_t)buffer_correction, PA_SEEK_RELATIVE, true); } } diff --git a/src/modules/raop/raop-client.c b/src/modules/raop/raop-client.c index ae950f7..8fca4df 100644 --- a/src/modules/raop/raop-client.c +++ b/src/modules/raop/raop-client.c @@ -669,7 +669,11 @@ static size_t handle_udp_timing_packet(pa_raop_client *c, const uint8_t packet[] payload = packet[1] ^ 0x80; switch (payload) { case PAYLOAD_TIMING_REQUEST: +#ifdef __TIZEN__ + pa_log_debug("Sending timing packet at %llu", rci); +#else pa_log_debug("Sending timing packet at %lu", rci); +#endif written = send_udp_timing_packet(c, data, rci); break; case PAYLOAD_TIMING_REPLY: -- 2.7.4