Invalid parsed value for keys_zone. Is this a problem?

Igor Sysoev igor at sysoev.ru
Tue Jan 18 17:40:53 MSK 2011


On Tue, Jan 18, 2011 at 04:29:16PM +0200, Eugaia wrote:

> Hi,
> 
> On 18/01/2011 16:20, Igor Sysoev wrote:
> > 10485760000 is 0x271000000 in hex. On 32-bit platform it's truncated to
> > 0x71000000, i.e., 1895825408. Yes, it should be checked.
> >
> Also, would it not be better to use off64_t or some other larger type 
> for storing the max_size of the cache (or indeed for parsing off's in 
> general)?  I'm not sure about all Posix systems, but on Debian off_t is 
> long int, hence a 32-bit value on 32-bit systems.  I've not checked in 
> the code, but I'm assuming that the max size of a file cache on 32-bit 
> systems may then be 2GB.

nginx uses 64-bit offsets on Linux with
#define _FILE_OFFSET_BITS  64


-- 
Igor Sysoev
http://sysoev.ru/en/



More information about the nginx mailing list