This commit is contained in:
2025-04-23 11:41:06 +08:00
parent 1e00348e84
commit 1c28d55681
11 changed files with 89 additions and 102 deletions

View File

@@ -5,12 +5,12 @@
#include <libipset/ipset.h>
#include <stdio.h>
#include <stdarg.h>
#include <arpa/inet.h> // 包含 inet_pton 函数
#include <arpa/inet.h> // 包含 inet_pton 函数
#define BUFFER 1024
#define MAX_CMD_LENGTH 256 // 或者根据需要调整
#define MAX_CMD_LENGTH 256 // 或者根据需要调整
extern int create_ipset( char *set_name);
extern int create_ipset(char *set_name);
extern int add_ip_to_ipset(char *set_name, char *ip);
extern int get_ip_count_in_ipset(char *set_name);