优化退出信号传递流程
This commit is contained in:
@ -5,7 +5,11 @@
|
||||
#include <stddef.h>
|
||||
#include <string.h>
|
||||
#include <termios.h>
|
||||
#include <pthread.h>
|
||||
#include <signal.h>
|
||||
|
||||
#include "ctl.h"
|
||||
|
||||
#include "interpreter/interpreter.h"
|
||||
#include "tools/log/log.h"
|
||||
|
||||
@ -248,6 +252,8 @@ int teml(Ctl *self,int fifo[2])
|
||||
const char fexp[256] = {'\0'};
|
||||
memcpy(&input,&fexp,MAX_BUF);
|
||||
}while(command->statue == 0);
|
||||
pthread_kill(self->logwathcher,SIGUSR1);
|
||||
//关闭log定期清理程序
|
||||
close(fifo[0]);
|
||||
close(fifo[1]);
|
||||
free_history(self);
|
||||
|
Reference in New Issue
Block a user