28 lines
490 B
C
28 lines
490 B
C
#ifndef MAIN_H
|
|
#define MAIN_h
|
|
|
|
#include <stdio.h>
|
|
#include <unistd.h>
|
|
#include <string.h>
|
|
#include <stdlib.h>
|
|
#include <sys/wait.h>
|
|
#include <arpa/inet.h>
|
|
#include <sys/resource.h>
|
|
#include <signal.h>
|
|
#include <sys/prctl.h>
|
|
|
|
#include "ip2region.h"
|
|
#include "qqwry.h"
|
|
#include "common.h"
|
|
|
|
#define RED "\033[31m"
|
|
#define RESET "\033[0m"
|
|
#define WHITELIST_IP_NUM 1024
|
|
#define MAXIPSET 65534
|
|
|
|
|
|
char *xdb_path = "ip2region.xdb";
|
|
pid_t pid1, pid2; // 保存子进程的 PID
|
|
|
|
#endif
|