优化源码配置宏位置,方便个性化编译

This commit is contained in:
2025-12-16 09:13:30 +08:00
parent 08589dfe79
commit cd75b098f5
9 changed files with 62 additions and 36 deletions

View File

@ -1,10 +1,10 @@
#ifndef LOG
#define LOG
#include "config.h"
#include <semaphore.h>
#include <pthread.h>
#define MAX_LOG 256
typedef struct logs
{

View File

@ -24,17 +24,20 @@ int quit_server(netm *self)
//关闭epoll监听
if(self->http_fd != -1)
{
close(self->http_fd);
if(close(self->http_fd)==-1)
return -1;
self->http_fd =-1;
}
//关闭socket监听
if(self->fifo_fd[1] != -1)
{
close(self->fifo_fd[1]);
if(close(self->fifo_fd[1])==-1)
return -1;
self->fifo_fd[1] = -1;
}
//关闭管道监听
free(self->err_indictor);
return 0;
}
void quit_all(int status,void *self_p)