Re: [spice-server v2 06/10] sound: Remove code from spice_server_record_get_samples()

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

 



> 
> It's ok to remove it because ?
> 
> Based on a patch from Frediano Ziglio <fziglio@xxxxxxxxxx>
> 
> Signed-off-by: Christophe Fergeau <cfergeau@xxxxxxxxxx>

Because I hate polling and was removed time ago :)

Really, now RedChannelClient try to send/receive data when it can
reducing latency.
This code was here as it was possible that some data was still
pending on the receiving queue due to some polling so it
try to read queue directly if buffer was not fill correctly.

> ---
>  server/sound.c | 9 ---------
>  1 file changed, 9 deletions(-)
> 
> diff --git a/server/sound.c b/server/sound.c
> index 28a290c..6025972 100644
> --- a/server/sound.c
> +++ b/server/sound.c
> @@ -1475,15 +1475,6 @@ SPICE_GNUC_VISIBLE uint32_t
> spice_server_record_get_samples(SpiceRecordInstance
>  
>      len = MIN(record_client->write_pos - record_client->read_pos, bufsize);
>  
> -    if (len < bufsize) {
> -        SndChannel *channel =
> SND_CHANNEL(red_channel_client_get_channel(client->channel_client));
> -        snd_receive(client);
> -        if (!channel->connection) {
> -            return 0;
> -        }
> -        len = MIN(record_client->write_pos - record_client->read_pos,
> bufsize);
> -    }
> -
>      read_pos = record_client->read_pos % RECORD_SAMPLES_SIZE;
>      record_client->read_pos += len;
>      now = MIN(len, RECORD_SAMPLES_SIZE - read_pos);

Frediano
_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]