mirror of
https://gitee.com/openharmony/third_party_ffmpeg
synced 2024-11-26 20:50:34 +00:00
!339 fix dirty data makes read err
Merge pull request !339 from 孙钰杰1/master
This commit is contained in:
commit
4393abf9b1
@ -3549,6 +3549,9 @@ static int mpegts_resync(AVFormatContext *s, int seekback, const uint8_t *curren
|
||||
if (avio_feof(pb))
|
||||
return AVERROR_EOF;
|
||||
if (c == 0x47) {
|
||||
#ifdef OHOS_OPT_COMPAT
|
||||
avio_seek(pb, -1, SEEK_CUR);
|
||||
#else
|
||||
int new_packet_size, ret;
|
||||
avio_seek(pb, -1, SEEK_CUR);
|
||||
pos = avio_tell(pb);
|
||||
@ -3561,6 +3564,7 @@ static int mpegts_resync(AVFormatContext *s, int seekback, const uint8_t *curren
|
||||
ts->raw_packet_size = new_packet_size;
|
||||
}
|
||||
avio_seek(pb, pos, SEEK_SET);
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user