mirror of
https://gitee.com/openharmony/third_party_ffmpeg
synced 2024-11-23 11:19:55 +00:00
fix dirty data makes read err
Signed-off-by: sunyujie <1458565796@qq.com>
This commit is contained in:
parent
89131c6c1c
commit
4df8b3cad4
1
BUILD.gn
1
BUILD.gn
@ -148,7 +148,6 @@ config("ffmpeg_config") {
|
|||||||
"-DOHOS_EXPAND_MP4_INFO",
|
"-DOHOS_EXPAND_MP4_INFO",
|
||||||
"-DOHOS_OPTIMIZE_DELAY",
|
"-DOHOS_OPTIMIZE_DELAY",
|
||||||
"-DOHOS_AV3A_DEMUXER",
|
"-DOHOS_AV3A_DEMUXER",
|
||||||
"-DOHOS_FRAME_TYPE_COMPAT",
|
|
||||||
]
|
]
|
||||||
if (use_musl) {
|
if (use_musl) {
|
||||||
cflags += [ "-Wno-bool-operation" ]
|
cflags += [ "-Wno-bool-operation" ]
|
||||||
|
@ -3549,8 +3549,8 @@ static int mpegts_resync(AVFormatContext *s, int seekback, const uint8_t *curren
|
|||||||
if (avio_feof(pb))
|
if (avio_feof(pb))
|
||||||
return AVERROR_EOF;
|
return AVERROR_EOF;
|
||||||
if (c == 0x47) {
|
if (c == 0x47) {
|
||||||
#ifdef OHOS_FRAME_TYPE_COMPAT
|
#ifdef OHOS_OPT_COMPAT
|
||||||
avio_seek(pb, -1, SEEK_CUR);
|
avio_seek(pb, -1, SEEK_CUR);
|
||||||
#else
|
#else
|
||||||
int new_packet_size, ret;
|
int new_packet_size, ret;
|
||||||
avio_seek(pb, -1, SEEK_CUR);
|
avio_seek(pb, -1, SEEK_CUR);
|
||||||
@ -3565,7 +3565,7 @@ static int mpegts_resync(AVFormatContext *s, int seekback, const uint8_t *curren
|
|||||||
}
|
}
|
||||||
avio_seek(pb, pos, SEEK_SET);
|
avio_seek(pb, pos, SEEK_SET);
|
||||||
#endif
|
#endif
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
av_log(s, AV_LOG_ERROR,
|
av_log(s, AV_LOG_ERROR,
|
||||||
|
Loading…
Reference in New Issue
Block a user