mirror of
https://github.com/nginx/nginx.git
synced 2025-06-07 09:42:39 +08:00
NGX_ENOPATH
This commit is contained in:
parent
98ab9ce988
commit
c9538c069f
@ -99,13 +99,7 @@ ngx_create_temp_file(ngx_file_t *file, ngx_path_t *path, ngx_pool_t *pool,
|
||||
continue;
|
||||
}
|
||||
|
||||
if ((path->level[0] == 0)
|
||||
|| (err != NGX_ENOENT
|
||||
#if (NGX_WIN32)
|
||||
&& err != NGX_ENOTDIR
|
||||
#endif
|
||||
))
|
||||
{
|
||||
if ((path->level[0] == 0) || (err != NGX_ENOPATH)) {
|
||||
ngx_log_error(NGX_LOG_CRIT, file->log, err,
|
||||
ngx_open_tempfile_n " \"%s\" failed",
|
||||
file->name.data);
|
||||
@ -560,14 +554,8 @@ ngx_ext_rename_file(ngx_str_t *src, ngx_str_t *to, ngx_ext_rename_file_t *ext)
|
||||
|
||||
err = ngx_errno;
|
||||
|
||||
if (err
|
||||
#if (NGX_WIN32)
|
||||
== ERROR_PATH_NOT_FOUND
|
||||
#else
|
||||
== NGX_ENOENT
|
||||
#endif
|
||||
)
|
||||
{
|
||||
if (err == NGX_ENOPATH) {
|
||||
|
||||
if (!ext->create_path) {
|
||||
goto failed;
|
||||
}
|
||||
|
@ -16,6 +16,7 @@ typedef int ngx_err_t;
|
||||
|
||||
#define NGX_EPERM EPERM
|
||||
#define NGX_ENOENT ENOENT
|
||||
#define NGX_ENOPATH ENOENT
|
||||
#define NGX_ESRCH ESRCH
|
||||
#define NGX_EINTR EINTR
|
||||
#define NGX_ECHILD ECHILD
|
||||
|
@ -21,6 +21,7 @@ typedef DWORD ngx_err_t;
|
||||
|
||||
#define NGX_EPERM ERROR_ACCESS_DENIED
|
||||
#define NGX_ENOENT ERROR_FILE_NOT_FOUND
|
||||
#define NGX_ENOPATH ERROR_PATH_NOT_FOUND
|
||||
#define NGX_ENOMEM ERROR_NOT_ENOUGH_MEMORY
|
||||
#define NGX_EACCES ERROR_ACCESS_DENIED
|
||||
/* it's seems that ERROR_FILE_EXISTS is not appropriate error code */
|
||||
|
Loading…
Reference in New Issue
Block a user