Skip to content

Commit 5507823

Browse files
committed
fixed crash in hls
1 parent 5c8d5b3 commit 5507823

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

hls/ngx_rtmp_hls_module.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -1800,7 +1800,8 @@ ngx_rtmp_hls_video(ngx_rtmp_session_t *s, ngx_rtmp_header_t *h,
18001800
*/
18011801

18021802
b = ctx->aframe;
1803-
boundary = frame.key && (codec_ctx->aac_header == NULL || b->last > b->pos);
1803+
boundary = frame.key && (codec_ctx->aac_header == NULL ||
1804+
(b && b->last > b->pos));
18041805

18051806
ngx_rtmp_hls_update_fragment(s, frame.dts, boundary, 1);
18061807

0 commit comments

Comments
 (0)