正在显示
1 个修改的文件
包含
6 行增加
和
0 行删除
| @@ -731,6 +731,12 @@ int SrsHlsCache::write_audio(SrsAvcAacCodec* codec, SrsHlsMuxer* muxer, int64_t | @@ -731,6 +731,12 @@ int SrsHlsCache::write_audio(SrsAvcAacCodec* codec, SrsHlsMuxer* muxer, int64_t | ||
| 731 | } | 731 | } |
| 732 | } | 732 | } |
| 733 | 733 | ||
| 734 | + // cache->audio will be free in flush_audio | ||
| 735 | + // so we must check whether it's null ptr. | ||
| 736 | + if (!cache->audio) { | ||
| 737 | + return ret; | ||
| 738 | + } | ||
| 739 | + | ||
| 734 | // TODO: config it. | 740 | // TODO: config it. |
| 735 | // in ms, audio delay to flush the audios. | 741 | // in ms, audio delay to flush the audios. |
| 736 | int64_t audio_delay = SRS_CONF_DEFAULT_AAC_DELAY; | 742 | int64_t audio_delay = SRS_CONF_DEFAULT_AAC_DELAY; |
-
请 注册 或 登录 后发表评论