aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMaxim Dounin <mdounin@mdounin.ru>2012-01-16 11:03:27 +0000
committerMaxim Dounin <mdounin@mdounin.ru>2012-01-16 11:03:27 +0000
commit9572920af06cf50de76b25060948cac322458f9e (patch)
tree4dd9c9a9168688e13a949694dbe1b19ba8320f12 /src
parent2c55914a9fad0938dd35b2c6ae99cc7f568ada9c (diff)
downloadnginx-9572920af06cf50de76b25060948cac322458f9e.tar.gz
nginx-9572920af06cf50de76b25060948cac322458f9e.zip
Fixed handling of mp4 above 2G and 32bit offsets (ticket #84).
Diffstat (limited to 'src')
-rw-r--r--src/http/modules/ngx_http_mp4_module.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/http/modules/ngx_http_mp4_module.c b/src/http/modules/ngx_http_mp4_module.c
index 7bfb3db66..6de7c8fea 100644
--- a/src/http/modules/ngx_http_mp4_module.c
+++ b/src/http/modules/ngx_http_mp4_module.c
@@ -165,10 +165,10 @@ typedef struct {
((u_char *) (p))[7] = n4
#define ngx_mp4_get_32value(p) \
- ( (((u_char *) (p))[0] << 24) \
- + (((u_char *) (p))[1] << 16) \
- + (((u_char *) (p))[2] << 8) \
- + (((u_char *) (p))[3]) )
+ ( ((uint32_t) ((u_char *) (p))[0] << 24) \
+ + ( ((u_char *) (p))[1] << 16) \
+ + ( ((u_char *) (p))[2] << 8) \
+ + ( ((u_char *) (p))[3]) )
#define ngx_mp4_set_32value(p, n) \
((u_char *) (p))[0] = (u_char) ((n) >> 24); \