Files
ucvl-zonghengjia-android/hev-socks5-tunnel/src/misc/hev-utils.h
T
2026-09-03 11:07:02 +08:00

26 lines
808 B
C

/*
============================================================================
Name : hev-utils.h
Author : hev <r@hev.cc>
Copyright : Copyright (c) 2023 hev
Description : Utils
============================================================================
*/
#ifndef __HEV_UTILS_H__
#define __HEV_UTILS_H__
#include <lwip/ip_addr.h>
#include <hev-socks5-proto.h>
void run_as_daemon (const char *pid_file);
int set_limit_nofile (int limit_nofile);
int set_sock_mark (int fd, unsigned int mark);
int hev_socks5_addr_from_lwip (HevSocks5Addr *addr, const ip_addr_t *ip,
u16_t port);
int hev_socks5_addr_into_lwip (const HevSocks5Addr *addr, ip_addr_t *ip,
u16_t *port);
#endif /* __HEV_UTILS_H__ */