From 6671983d86a49410f0503c753c4e20d78f4296fc Mon Sep 17 00:00:00 2001 From: Igor Sysoev Date: Thu, 27 Nov 2008 14:24:39 +0000 Subject: r2087 merge: allow several values in query string --- src/http/modules/ngx_http_flv_module.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/http') diff --git a/src/http/modules/ngx_http_flv_module.c b/src/http/modules/ngx_http_flv_module.c index 0e190910c..07bf5beb5 100644 --- a/src/http/modules/ngx_http_flv_module.c +++ b/src/http/modules/ngx_http_flv_module.c @@ -60,7 +60,7 @@ ngx_module_t ngx_http_flv_module = { static ngx_int_t ngx_http_flv_handler(ngx_http_request_t *r) { - u_char *p, *last; + u_char *p, *n, *last; off_t start, len; size_t root; ngx_int_t rc; @@ -168,7 +168,13 @@ ngx_http_flv_handler(ngx_http_request_t *r) if (p) { p += 6; - start = ngx_atoof(p, r->args.len - (p - r->args.data)); + for (n = p; n < r->args.data + r->args.len; n++) { + if (*n == '&') { + break; + } + } + + start = ngx_atoof(p, n - p); if (start == NGX_ERROR || start >= len) { start = 0; -- cgit