From b9177d36e71a9f62198b00fa40f277c06d2264bb Mon Sep 17 00:00:00 2001 From: Andrew Clayton Date: Mon, 27 Mar 2023 19:28:54 +0100 Subject: Remove a bunch of dead code. This removes a bunch of unused files that would have been touched by subsequent commits that switch to using nxt_bool_t (AKA unit6_t) in structures. In auto/sources we have NXT_LIB_SRC0=" \ src/nxt_buf_filter.c \ src/nxt_job_file.c \ src/nxt_stream_module.c \ src/nxt_stream_source.c \ src/nxt_upstream_source.c \ src/nxt_http_source.c \ src/nxt_fastcgi_source.c \ src/nxt_fastcgi_record_parse.c \ \ src/nxt_mem_pool_cleanup.h \ src/nxt_mem_pool_cleanup.c \ " None of these seem to actually be used anywhere (other than within themselves). That variable is _not_ referenced anywhere else. Also remove the unused related header files: src/nxt_buf_filter.h, src/nxt_fastcgi_source.h, src/nxt_http_source.h, src/nxt_job_file.h, src/nxt_stream_source.h and src/nxt_upstream_source.h Also, these files do not seem to be used, no mention under auto/ or build/ src/nxt_file_cache.c src/nxt_cache.c src/nxt_job_file_cache.c src/nxt_cache.h is #included in src/nxt_main.h, but AFAICT is not actually used. With all the above removed $ ./configure --openssl --debug --tests && make -j && make -j tests && make libnxt all builds. Buildbot passes. NOTE: You may need to do a 'make clean' before the next build attempt. Reviewed-by: Alejandro Colomar Signed-off-by: Andrew Clayton --- src/nxt_main.h | 4 ---- 1 file changed, 4 deletions(-) (limited to 'src/nxt_main.h') diff --git a/src/nxt_main.h b/src/nxt_main.h index b0cdc2d3..75e1724e 100644 --- a/src/nxt_main.h +++ b/src/nxt_main.h @@ -145,13 +145,9 @@ typedef void (*nxt_event_conn_handler_t)(nxt_thread_t *thr, nxt_conn_t *c); #include #include -#include -#include #include -#include - #include #include #include -- cgit From 1fd6eb626baeee94a65b199cd848019e0e6b81b3 Mon Sep 17 00:00:00 2001 From: Andrew Clayton Date: Tue, 21 Mar 2023 22:46:42 +0000 Subject: Decouple "Unit" from NXT_SERVER. Split out the "Unit" name from the NXT_SERVER #define into its own NXT_NAME #define, then make NXT_SERVER a combination of that and NXT_VERSION. This is required for a subsequent commit where we may want the server name on its own. Reviewed-by: Alejandro Colomar Signed-off-by: Andrew Clayton --- src/nxt_main.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/nxt_main.h') diff --git a/src/nxt_main.h b/src/nxt_main.h index 75e1724e..a7e0c283 100644 --- a/src/nxt_main.h +++ b/src/nxt_main.h @@ -11,7 +11,8 @@ #include #include -#define NXT_SERVER "Unit/" NXT_VERSION +#define NXT_NAME "Unit" +#define NXT_SERVER NXT_NAME "/" NXT_VERSION typedef struct nxt_port_s nxt_port_t; typedef struct nxt_task_s nxt_task_t; -- cgit