Kouhei Sutou
null+****@clear*****
Thu Oct 3 17:11:12 JST 2013
Kouhei Sutou 2013-10-03 17:11:12 +0900 (Thu, 03 Oct 2013) New Revision: 2dbc2c541bb0918487be595d13efe6981124c18e https://github.com/groonga/groonga/commit/2dbc2c541bb0918487be595d13efe6981124c18e Message: Remove a restriction related to RLIMIT_NOFILE on HTTP server GQTP server can use 4096 over RLIMIT_NOFILE but HTTP server couldn't. Modified files: src/groonga.c Modified: src/groonga.c (+1 -14) =================================================================== --- src/groonga.c 2013-10-03 15:05:33 +0900 (c9fe0d0) +++ src/groonga.c 2013-10-03 17:11:12 +0900 (1d66bcf) @@ -1431,20 +1431,7 @@ h_server(char *path) CRITICAL_SECTION_INIT(cache_lock); GRN_COM_QUEUE_INIT(&ctx_new); GRN_COM_QUEUE_INIT(&ctx_old); -#ifndef WIN32 - { - struct rlimit lim; - lim.rlim_cur = 4096; - lim.rlim_max = 4096; - /* RLIMIT_OFILE */ - setrlimit(RLIMIT_NOFILE, &lim); - lim.rlim_cur = 0; - lim.rlim_max = 0; - getrlimit(RLIMIT_NOFILE, &lim); - GRN_LOG(ctx, GRN_LOG_NOTICE, "RLIMIT_NOFILE(%" GRN_FMT_LLD ",%" GRN_FMT_LLD ")", - (long long int)lim.rlim_cur, (long long int)lim.rlim_max); - } -#endif /* WIN32 */ + check_rlimit_nofile(ctx); exit_code = start_service(ctx, path, NULL, h_handler); grn_ctx_fin(ctx); return exit_code; -------------- next part -------------- HTML����������������������������... Download