mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
fix #151, always reap ts whatever audio or video packet. 0.9.223.
This commit is contained in:
parent
13b092704d
commit
9789335d0b
6 changed files with 22 additions and 20 deletions
|
@ -400,7 +400,7 @@ int SrsGopCache::cache(SrsSharedPtrMessage* msg)
|
|||
}
|
||||
|
||||
// no acceptable video or pure audio, disable the cache.
|
||||
if (cached_video_count == 0) {
|
||||
if (pure_audio()) {
|
||||
srs_verbose("ignore any frame util got a h264 video frame.");
|
||||
return ret;
|
||||
}
|
||||
|
@ -482,6 +482,11 @@ int64_t SrsGopCache::start_time()
|
|||
return msg->header.timestamp;
|
||||
}
|
||||
|
||||
bool SrsGopCache::pure_audio()
|
||||
{
|
||||
return cached_video_count == 0;
|
||||
}
|
||||
|
||||
std::map<std::string, SrsSource*> SrsSource::pool;
|
||||
|
||||
int SrsSource::find(SrsRequest* req, SrsSource** ppsource)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue