comparison src/os/unix/ngx_files.h @ 416:a8e3f1441eec NGINX_0_7_17

nginx 0.7.17 *) Feature: now the "directio" directive works on Linux. *) Feature: the $pid variable. *) Bugfix: the "directio" optimization that had appeared in 0.7.15 did not work with open_file_cache. *) Bugfix: the "access_log" with variables did not work on Linux; the bug had appeared in 0.7.7. *) Bugfix: the ngx_http_charset_module did not understand quoted charset name received from backend.
author Igor Sysoev <http://sysoev.ru>
date Mon, 15 Sep 2008 00:00:00 +0400
parents 79c5df00501e
children b246022ef454
comparison
equal deleted inserted replaced
415:f6561f721532 416:a8e3f1441eec
220 #define ngx_unlock_fd_n "fcntl(F_SETLK, F_UNLCK)" 220 #define ngx_unlock_fd_n "fcntl(F_SETLK, F_UNLCK)"
221 221
222 222
223 #if (NGX_HAVE_O_DIRECT) 223 #if (NGX_HAVE_O_DIRECT)
224 224
225 ngx_int_t ngx_directio(ngx_fd_t fd); 225 ngx_int_t ngx_directio_on(ngx_fd_t fd);
226 #define ngx_directio_n "fcntl(O_DIRECT)" 226 #define ngx_directio_on_n "fcntl(O_DIRECT)"
227
228 ngx_int_t ngx_directio_off(ngx_fd_t fd);
229 #define ngx_directio_off_n "fcntl(!O_DIRECT)"
227 230
228 #elif (NGX_HAVE_F_NOCACHE) 231 #elif (NGX_HAVE_F_NOCACHE)
229 232
230 #define ngx_directio(fd) fcntl(fd, F_NOCACHE, 1) 233 #define ngx_directio_on(fd) fcntl(fd, F_NOCACHE, 1)
231 #define ngx_directio_n "fcntl(F_NOCACHE)" 234 #define ngx_directio_on_n "fcntl(F_NOCACHE, 1)"
232 235
233 #elif (NGX_HAVE_DIRECTIO) 236 #elif (NGX_HAVE_DIRECTIO)
234 237
235 #define ngx_directio(fd) directio(fd, DIRECTIO_ON) 238 #define ngx_directio_on(fd) directio(fd, DIRECTIO_ON)
236 #define ngx_directio_n "directio(DIRECTIO_ON)" 239 #define ngx_directio_on_n "directio(DIRECTIO_ON)"
237 240
238 #else 241 #else
239 242
240 #define ngx_directio(fd) 0 243 #define ngx_directio_on(fd) 0
241 #define ngx_directio_n "ngx_directio_n" 244 #define ngx_directio_on_n "ngx_directio_on_n"
242 245
243 #endif 246 #endif
244 247
245 248
246 #endif /* _NGX_FILES_H_INCLUDED_ */ 249 #endif /* _NGX_FILES_H_INCLUDED_ */