diff options
| author | Igor Sysoev <igor@sysoev.ru> | 2010-02-01 15:06:25 +0000 |
|---|---|---|
| committer | Igor Sysoev <igor@sysoev.ru> | 2010-02-01 15:06:25 +0000 |
| commit | 208bda2807116263017f848d9c1cc8e380fd6323 (patch) | |
| tree | 5f709c1507934a231850116b9093f8dd88449eee /src/core/ngx_output_chain.c | |
| parent | 82f12f79110b9a66c5ff5574f7156b67d0f2d462 (diff) | |
| download | nginx-208bda2807116263017f848d9c1cc8e380fd6323.tar.gz nginx-208bda2807116263017f848d9c1cc8e380fd6323.tar.bz2 | |
merge r3138, r3139, r3157, r3158, r3159, r3164, r3165,
r3202, r3203, r3383, r3388, r3417, r3418:
Win32 (mostly) and some Unix file related fixes:
*) preserve errno while ngx_free()
*) win32 ngx_file_info() utf8 support
*) delete Win95 code
*) log file name for read/write errors
*) test incomplete WriteFile()
*) handle short pwrite() to log an error cause: ENOSPC, EDQUOT, or EFBIG
*) uniform ngx_directio_on/off() interface with other file functions
*) do not create Win32 drive letter in ngx_create_full_path()
*) ignore EACCES errors for top level directories in ngx_create_full_path()
*) fix Win32 error messages when an temporary file replaces an existent file:
*) do not rename an already renamed file
*) now ngx_win32_rename_file() returns error code
*) do not log failure inside ngx_win32_rename_file()
*) fix Win32 error message when an temporary file replaces an existent file:
return at once if ngx_win32_rename_file() was not failed
and do not try to delete already the renamed temporary file
*) skip URI trailing spaces under Win32
*) disable Win32 short file names
Diffstat (limited to 'src/core/ngx_output_chain.c')
| -rw-r--r-- | src/core/ngx_output_chain.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/ngx_output_chain.c b/src/core/ngx_output_chain.c index bee7952ca..808addd85 100644 --- a/src/core/ngx_output_chain.c +++ b/src/core/ngx_output_chain.c @@ -510,7 +510,7 @@ ngx_output_chain_copy_buf(ngx_output_chain_ctx_t *ctx) #if (NGX_HAVE_ALIGNED_DIRECTIO) if (ctx->unaligned) { - if (ngx_directio_off(src->file->fd) == -1) { + if (ngx_directio_off(src->file->fd) == NGX_FILE_ERROR) { ngx_log_error(NGX_LOG_ALERT, ctx->pool->log, ngx_errno, ngx_directio_off_n " \"%s\" failed", src->file->name.data); @@ -528,7 +528,7 @@ ngx_output_chain_copy_buf(ngx_output_chain_ctx_t *ctx) err = ngx_errno; - if (ngx_directio_on(src->file->fd) == -1) { + if (ngx_directio_on(src->file->fd) == NGX_FILE_ERROR) { ngx_log_error(NGX_LOG_ALERT, ctx->pool->log, ngx_errno, ngx_directio_on_n " \"%s\" failed", src->file->name.data); |
