mirror of
https://github.com/zotanmew/nginx-rtmp-module.git
synced 2024-05-10 14:31:07 +02:00
Fix missing var, check if record have opened file
This commit is contained in:
parent
dec648681d
commit
4e17054a6d
|
@ -418,7 +418,7 @@ ngx_rtmp_stat_live(ngx_http_request_t *r, ngx_chain_t ***lll,
|
||||||
ngx_rtmp_record_ctx_t *rctx;
|
ngx_rtmp_record_ctx_t *rctx;
|
||||||
ngx_rtmp_record_rec_ctx_t *recctx;
|
ngx_rtmp_record_rec_ctx_t *recctx;
|
||||||
ngx_rtmp_session_t *s;
|
ngx_rtmp_session_t *s;
|
||||||
ngx_int_t n;
|
ngx_int_t n, rn;
|
||||||
ngx_uint_t nclients, total_nclients;
|
ngx_uint_t nclients, total_nclients;
|
||||||
u_char buf[NGX_INT_T_LEN];
|
u_char buf[NGX_INT_T_LEN];
|
||||||
u_char bbuf[NGX_INT32_LEN];
|
u_char bbuf[NGX_INT32_LEN];
|
||||||
|
@ -501,7 +501,7 @@ ngx_rtmp_stat_live(ngx_http_request_t *r, ngx_chain_t ***lll,
|
||||||
if (rctx) {
|
if (rctx) {
|
||||||
recctx = rctx->rec.elts;
|
recctx = rctx->rec.elts;
|
||||||
for (rn = 0; rn < rctx->rec.nelts; ++rn, ++recctx) {
|
for (rn = 0; rn < rctx->rec.nelts; ++rn, ++recctx) {
|
||||||
if (recctx->initialized) {
|
if (recctx->initialized && recctx->file.fd != NGX_INVALID_FILE) {
|
||||||
NGX_RTMP_STAT_L("<recording/>");
|
NGX_RTMP_STAT_L("<recording/>");
|
||||||
is_recording = 1;
|
is_recording = 1;
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue