view src/os/win32/ngx_alloc.h @ 5348:317e0893a1e6

Image filter: large image handling. If Content-Length header is not set, and the image size is larger than the buffer size, client will hang until a timeout occurs. Now NGX_HTTP_UNSUPPORTED_MEDIA_TYPE is returned immediately. diff -r d1403de41631 -r 4fae04f332b4 src/http/modules/ngx_http_image_filter_module.c
author Lanshun Zhou <zls.sogou@gmail.com>
date Wed, 28 Aug 2013 00:19:07 +0800
parents d620f497c50f
children
line wrap: on
line source


/*
 * Copyright (C) Igor Sysoev
 * Copyright (C) Nginx, Inc.
 */


#ifndef _NGX_ALLOC_H_INCLUDED_
#define _NGX_ALLOC_H_INCLUDED_


#include <ngx_config.h>
#include <ngx_core.h>


void *ngx_alloc(size_t size, ngx_log_t *log);
void *ngx_calloc(size_t size, ngx_log_t *log);

#define ngx_free          free
#define ngx_memalign(alignment, size, log)  ngx_alloc(size, log)

extern ngx_uint_t  ngx_pagesize;
extern ngx_uint_t  ngx_pagesize_shift;
extern ngx_uint_t  ngx_cacheline_size;


#endif /* _NGX_ALLOC_H_INCLUDED_ */