Re: [PATCH BlueZ 2/2] AVRCP: Don't respond with errors when no player is registered

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Oct 16, 2012 at 8:58 AM, Luiz Augusto von Dentz
<luiz.dentz@xxxxxxxxx> wrote:
> From: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>
>
> Some devices w.g. Sony MW600 will stop using certain commands if an
> error happen, so the code now just fake a player and once a real
> player is registered it takes place of the fake one.
> ---
>  audio/avrcp.c | 91 ++++++++++++++++++++++++++++++++++++++++++++++++-----------
>  1 file changed, 74 insertions(+), 17 deletions(-)
>
> diff --git a/audio/avrcp.c b/audio/avrcp.c
> index 5a18cb4..cd57358 100644
> --- a/audio/avrcp.c
> +++ b/audio/avrcp.c
> @@ -493,6 +493,28 @@ void avrcp_player_event(struct avrcp_player *player, uint8_t id, void *data)
>         return;
>  }
>
> +static const char *player_get_string(struct avrcp_player *player, uint32_t attr)
> +{

Instead of adding these wrapper functions, did you consider having a
default_avrcp_player with all hooks set and player pointing to it if
there's no player registered?

Lucas De Marchi
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux