]> git.kaiwu.me - nginx.git/commitdiff
cf->conf_file->file.name.data may be uninitialized, if an allocation failed;
authorIgor Sysoev <igor@sysoev.ru>
Thu, 5 Nov 2009 17:10:48 +0000 (17:10 +0000)
committerIgor Sysoev <igor@sysoev.ru>
Thu, 5 Nov 2009 17:10:48 +0000 (17:10 +0000)
found by Clang Static Analyzer

src/core/ngx_conf_file.c

index c58d8095fae4d73deeeb41dd433de82287e04899..c48d814f89b24b809a55e51e8ff31642bdab8bc4 100644 (file)
@@ -261,7 +261,7 @@ done:
         if (ngx_close_file(fd) == NGX_FILE_ERROR) {
             ngx_log_error(NGX_LOG_ALERT, cf->log, ngx_errno,
                           ngx_close_file_n " %s failed",
-                          cf->conf_file->file.name.data);
+                          filename->data);
             return NGX_CONF_ERROR;
         }