nginx-0.0.1-2003-11-21-09:30:49 import
diff --git a/src/os/unix/ngx_files.c b/src/os/unix/ngx_files.c
index 651113d..7563009 100644
--- a/src/os/unix/ngx_files.c
+++ b/src/os/unix/ngx_files.c
@@ -118,7 +118,8 @@
 
     if (cl->next == NULL) {
         return ngx_write_file(file, cl->hunk->pos,
-                              cl->hunk->last - cl->hunk->pos, offset);
+                              (size_t) (cl->hunk->last - cl->hunk->pos),
+                              offset);
     }
 
     prev = NULL;