summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/core/ngx_string.c2
-rw-r--r--src/http/modules/ngx_http_mp4_module.c2
-rw-r--r--src/os/win32/ngx_win32_config.h14
3 files changed, 16 insertions, 2 deletions
diff --git a/src/core/ngx_string.c b/src/core/ngx_string.c
index 3b392f7b2..d3ff36855 100644
--- a/src/core/ngx_string.c
+++ b/src/core/ngx_string.c
@@ -486,7 +486,7 @@ ngx_sprintf_num(u_char *buf, u_char *last, uint64_t ui64, u_char zero,
if (hexadecimal == 0) {
- if (ui64 <= NGX_MAX_UINT32_VALUE) {
+ if (ui64 <= (uint64_t) NGX_MAX_UINT32_VALUE) {
/*
* To divide 64-bit numbers and to find remainders
diff --git a/src/http/modules/ngx_http_mp4_module.c b/src/http/modules/ngx_http_mp4_module.c
index f9281a371..680b65871 100644
--- a/src/http/modules/ngx_http_mp4_module.c
+++ b/src/http/modules/ngx_http_mp4_module.c
@@ -1129,7 +1129,7 @@ ngx_http_mp4_update_mdat_atom(ngx_http_mp4_file_t *mp4, off_t start_offset)
atom_header = mp4->mdat_atom_header;
- if ((uint64_t) atom_data_size > 0xffffffff) {
+ if ((uint64_t) atom_data_size > (uint64_t) 0xffffffff) {
atom_size = 1;
atom_header_size = sizeof(ngx_mp4_atom_header64_t);
ngx_mp4_set_64value(atom_header + sizeof(ngx_mp4_atom_header_t),
diff --git a/src/os/win32/ngx_win32_config.h b/src/os/win32/ngx_win32_config.h
index 623569855..7face954f 100644
--- a/src/os/win32/ngx_win32_config.h
+++ b/src/os/win32/ngx_win32_config.h
@@ -128,13 +128,27 @@ typedef unsigned short int uint16_t;
typedef __int64 int64_t;
typedef unsigned __int64 uint64_t;
+
+#ifndef __WATCOMC__
typedef int intptr_t;
typedef u_int uintptr_t;
+#endif
+
/* Windows defines off_t as long, which is 32-bit */
typedef __int64 off_t;
#define _OFF_T_DEFINED
+#ifdef __WATCOMC__
+
+/* off_t is redefined by sys/types.h used by zlib.h */
+#define __TYPES_H_INCLUDED
+typedef int dev_t;
+typedef unsigned int ino_t;
+
+#endif
+
+
typedef int ssize_t;
typedef uint32_t in_addr_t;
typedef u_short in_port_t;