Kentaro Hayashi
null+****@clear*****
Mon Jun 5 16:44:20 JST 2017
Kentaro Hayashi 2017-06-05 16:44:20 +0900 (Mon, 05 Jun 2017) New Revision: 94292ebb675a1d1581359546d7b7f90a59d7b2a2 https://github.com/groonga/groonga/commit/94292ebb675a1d1581359546d7b7f90a59d7b2a2 Merged 53850e4: Merge pull request #701 from kenhys/add-more-add-log Message: Add more create operation logs It may be useful to identify lifetime of created files. Modified files: lib/io.c Modified: lib/io.c (+9 -0) =================================================================== --- lib/io.c 2017-06-05 16:34:31 +0900 (bbdc41b) +++ lib/io.c 2017-06-05 16:44:20 +0900 (6772bce) @@ -1693,6 +1693,9 @@ grn_fileinfo_open_common(grn_ctx *ctx, fileinfo *fi, const char *path, int flags SERR("CreateFile(<%s>, <%s>) failed", path, flags_description); goto exit; + } else { + GRN_LOG(ctx, GRN_LOG_INFO, + "[io][open] file is created on CreateFile: <%s>", path); } if (grn_io_use_sparse) { @@ -1729,6 +1732,9 @@ grn_fileinfo_open_common(grn_ctx *ctx, fileinfo *fi, const char *path, int flags SERR("CreateFile(<%s>, <O_RDWR|O_TRUNC>) failed", path); goto exit; + } else { + GRN_LOG(ctx, GRN_LOG_INFO, + "[io][open] file is truncated: <%s>", path); } goto exit; } @@ -1741,6 +1747,9 @@ grn_fileinfo_open_common(grn_ctx *ctx, fileinfo *fi, const char *path, int flags SERR("CreateFile(<%s>, <O_RDWR>) failed", path); goto exit; + } else { + GRN_LOG(ctx, GRN_LOG_INFO, + "[io][open] file is created: <%s>", path); } exit : -------------- next part -------------- HTML����������������������������... 下載