Ignore:
Timestamp:
Oct 31, 2011 10:31:23 AM (11 years ago)
Author:
ming
Message:

Re #1395: Backport of PJSIP 1.x branch into PJSIP 2.0 trunk

Location:
pjproject/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk

  • pjproject/trunk/pjmedia/src/pjmedia/wav_player.c

    r3664 r3878  
    462462    fport = (struct file_reader_port*) port; 
    463463 
    464     PJ_ASSERT_RETURN(bytes < fport->fsize - fport->start_data, PJ_EINVAL); 
     464    /* Check that this offset does not pass the audio-data (in case of 
     465     * extra chunk after audio data chunk 
     466     */ 
     467    PJ_ASSERT_RETURN(bytes < fport->data_len, PJ_EINVAL); 
    465468 
    466469    fport->fpos = fport->start_data + bytes; 
     470    fport->data_left = fport->data_len - bytes; 
    467471    pj_file_setpos( fport->fd, fport->fpos, PJ_SEEK_SET); 
    468472 
Note: See TracChangeset for help on using the changeset viewer.