From d5ae9958c1375eeb1caf49f3b45298f1d9687432 Mon Sep 17 00:00:00 2001 From: Sergey Dryabzhinsky Date: Sun, 28 Feb 2016 23:04:44 +0300 Subject: [PATCH] Adjust var types --- ngx_rtmp_bandwidth_detection_module.c | 4 ++-- ngx_rtmp_send.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ngx_rtmp_bandwidth_detection_module.c b/ngx_rtmp_bandwidth_detection_module.c index 27bcefc..925a762 100644 --- a/ngx_rtmp_bandwidth_detection_module.c +++ b/ngx_rtmp_bandwidth_detection_module.c @@ -356,7 +356,7 @@ ngx_rtmp_bandwidth_detection_fast(ngx_rtmp_session_t *s, ngx_rtmp_header_t *h, n ngx_rtmp_bandwidth_detection_app_conf_t *acf; ngx_rtmp_bandwidth_detection_ctx_t *bw_ctx; ngx_uint_t timePassed; - ngx_uint_t deltaDown; + double deltaDown; double deltaTime; double kbitDown; @@ -427,7 +427,7 @@ ngx_rtmp_bandwidth_detection_fast(ngx_rtmp_session_t *s, ngx_rtmp_header_t *h, n ngx_log_debug0(NGX_LOG_DEBUG_RTMP, s->connection->log, 0, "bandwidth_detection: fast - check done!"); ngx_log_debug5(NGX_LOG_DEBUG_RTMP, s->connection->log, 0, - "bandwidth_detection: fast - kbitDown=%ui, deltaDown=%.3f, deltaTime=%.3f, latency=%.3f, KBytes=%ui", + "bandwidth_detection: fast - kbitDown=%.3f, deltaDown=%.3f, deltaTime=%.3f, latency=%.3f, KBytes=%ui", kbitDown, deltaDown, deltaTime, bw_ctx->latency, (bw_ctx->bytes_out2 - bw_ctx->bytes_out)/1024); return ngx_rtmp_send_bwdone(s, kbitDown, deltaDown, deltaTime, bw_ctx->latency); diff --git a/ngx_rtmp_send.c b/ngx_rtmp_send.c index c5b5e31..082b165 100644 --- a/ngx_rtmp_send.c +++ b/ngx_rtmp_send.c @@ -1024,7 +1024,7 @@ ngx_rtmp_create_bwcheck(ngx_rtmp_session_t *s, u_char *payload, size_t plength) memset(&h, 0, sizeof(h)); h.type = NGX_RTMP_MSG_AMF_CMD; - h.csid = NGX_RTMP_CSID_AMF_INI; + h.csid = NGX_RTMP_CSID_AMF; h.msid = NGX_RTMP_MSID; return ngx_rtmp_create_amf(s, &h, out_elts, @@ -1095,7 +1095,7 @@ ngx_rtmp_create_bwdone(ngx_rtmp_session_t *s, memset(&h, 0, sizeof(h)); h.type = NGX_RTMP_MSG_AMF_CMD; - h.csid = NGX_RTMP_CSID_AMF_INI; + h.csid = NGX_RTMP_CSID_AMF; h.msid = NGX_RTMP_MSID; return ngx_rtmp_create_amf(s, &h, out_elts,