2005-02-20 14:27:00 +00:00
|
|
|
#ifndef _LIGHTTPD_SETTINGS_H_
|
|
|
|
#define _LIGHTTPD_SETTINGS_H_
|
|
|
|
|
|
|
|
#define BV(x) (1 << x)
|
|
|
|
|
|
|
|
#define INET_NTOP_CACHE_MAX 4
|
|
|
|
#define FILE_CACHE_MAX 16
|
|
|
|
|
|
|
|
/**
|
|
|
|
* max size of a buffer which will just be reset
|
|
|
|
* to ->used = 0 instead of really freeing the buffer
|
2006-10-04 13:26:23 +00:00
|
|
|
*
|
2005-02-20 14:27:00 +00:00
|
|
|
* 64kB (no real reason, just a guess)
|
|
|
|
*/
|
|
|
|
#define BUFFER_MAX_REUSE_SIZE (4 * 1024)
|
2009-04-26 18:29:09 +00:00
|
|
|
#define MAX_READ_LIMIT (4*1024*1024)
|
2005-02-20 14:27:00 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* max size of the HTTP request header
|
2006-10-04 13:26:23 +00:00
|
|
|
*
|
2005-02-20 14:27:00 +00:00
|
|
|
* 32k should be enough for everything (just a guess)
|
2006-10-04 13:26:23 +00:00
|
|
|
*
|
2005-02-20 14:27:00 +00:00
|
|
|
*/
|
|
|
|
#define MAX_HTTP_REQUEST_HEADER (32 * 1024)
|
|
|
|
|
2006-10-04 13:26:23 +00:00
|
|
|
typedef enum { HANDLER_UNSET,
|
|
|
|
HANDLER_GO_ON,
|
2005-02-20 14:27:00 +00:00
|
|
|
HANDLER_FINISHED,
|
2006-10-04 13:26:23 +00:00
|
|
|
HANDLER_COMEBACK,
|
|
|
|
HANDLER_WAIT_FOR_EVENT,
|
2005-02-20 14:27:00 +00:00
|
|
|
HANDLER_ERROR,
|
|
|
|
HANDLER_WAIT_FOR_FD
|
|
|
|
} handler_t;
|
|
|
|
|
|
|
|
|
|
|
|
/* we use it in a enum */
|
|
|
|
#ifdef TRUE
|
|
|
|
#undef TRUE
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef FALSE
|
|
|
|
#undef FALSE
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|