mirror of
https://github.com/wangyu-/udp2raw.git
synced 2025-01-19 06:19:31 +08:00
Compare commits
3 Commits
f5a8cbf9e6
...
f3e05f4a86
Author | SHA1 | Date | |
---|---|---|---|
|
f3e05f4a86 | ||
|
d1a9bcc4fb | ||
|
4559e6d47b |
@ -33,3 +33,5 @@ target_link_libraries(udp2raw rt)
|
|||||||
target_link_libraries(udp2raw pthread)
|
target_link_libraries(udp2raw pthread)
|
||||||
include_directories(SYSTEM "libev")
|
include_directories(SYSTEM "libev")
|
||||||
include_directories(".")
|
include_directories(".")
|
||||||
|
|
||||||
|
install(TARGETS udp2raw)
|
||||||
|
@ -702,7 +702,7 @@ void init_filter(int port) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int dummy;
|
int dummy=0;
|
||||||
|
|
||||||
int ret = setsockopt(raw_recv_fd, SOL_SOCKET, SO_DETACH_FILTER, &dummy, sizeof(dummy)); // in case i forgot to remove
|
int ret = setsockopt(raw_recv_fd, SOL_SOCKET, SO_DETACH_FILTER, &dummy, sizeof(dummy)); // in case i forgot to remove
|
||||||
if (ret != 0) {
|
if (ret != 0) {
|
||||||
@ -841,7 +841,7 @@ void init_filter(int port) {
|
|||||||
void remove_filter() {
|
void remove_filter() {
|
||||||
filter_port = 0;
|
filter_port = 0;
|
||||||
#ifdef UDP2RAW_LINUX
|
#ifdef UDP2RAW_LINUX
|
||||||
int dummy;
|
int dummy=0;
|
||||||
int ret = setsockopt(raw_recv_fd, SOL_SOCKET, SO_DETACH_FILTER, &dummy, sizeof(dummy));
|
int ret = setsockopt(raw_recv_fd, SOL_SOCKET, SO_DETACH_FILTER, &dummy, sizeof(dummy));
|
||||||
if (ret != 0) {
|
if (ret != 0) {
|
||||||
mylog(log_debug, "error remove fiter\n");
|
mylog(log_debug, "error remove fiter\n");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user