[PATCH] Re: wav-player broken for CCITT u/a-law files in 1.10 (and 2.x) after Ticket #597

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

 



Hello Benny,

I probably have the solution for mentioned problem. It was indeed that the
fport->data_left wasn't updated on a file-position change.
Please have a check if I did not oversee something, and please add it to the
1.x and 2.x tree.

File: wav-player.c
Function: pjmedia_wav_player_port_set_pos

Add next code after the last PJ_ASSERT_RETURN:

    /* Check that this offset does not pass the audio-data (in case of
       extra chunk after audio data chunk */
    PJ_ASSERT_RETURN(bytes < fport->data_len, PJ_EINVAL);
    fport->data_left = fport->data_len - bytes;


With regards,

Eize Slange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20111020/b8865e5a/attachment.html>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux