mirror of
https://github.com/wangyu-/udp2raw.git
synced 2025-01-19 22:39:31 +08:00
fixed core dumped from last commit
This commit is contained in:
parent
9f10fd4766
commit
84855a393c
2
common.h
2
common.h
@ -81,7 +81,7 @@ const uint32_t server_conn_timeout=conv_timeout+10000;//for test
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
enum raw_mode_t{mode_faketcp=1,mode_udp,mode_icmp,mode_end};
|
enum raw_mode_t{mode_faketcp=0,mode_udp,mode_icmp,mode_end};
|
||||||
extern raw_mode_t raw_mode;
|
extern raw_mode_t raw_mode;
|
||||||
enum program_mode_t {unset_mode=0,client_mode,server_mode};
|
enum program_mode_t {unset_mode=0,client_mode,server_mode};
|
||||||
extern program_mode_t program_mode;
|
extern program_mode_t program_mode;
|
||||||
|
2
main.cpp
2
main.cpp
@ -2700,6 +2700,8 @@ void process_arg(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
if(strcmp(optarg,raw_mode_tostring[i])==0)
|
if(strcmp(optarg,raw_mode_tostring[i])==0)
|
||||||
{
|
{
|
||||||
|
printf("%d i\n",i);
|
||||||
|
printf("%s",raw_mode_tostring[i]);
|
||||||
raw_mode=(raw_mode_t)i;
|
raw_mode=(raw_mode_t)i;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
2
makefile
2
makefile
@ -1,5 +1,5 @@
|
|||||||
ccmips=mips-openwrt-linux-g++
|
ccmips=mips-openwrt-linux-g++
|
||||||
FLAGS=-Wall -Wextra -Wno-unused-variable -Wno-unused-parameter -O3
|
FLAGS=-Wall -Wextra -Wno-unused-variable -Wno-unused-parameter
|
||||||
all:
|
all:
|
||||||
sudo killall udp2raw||true
|
sudo killall udp2raw||true
|
||||||
sleep 0.2
|
sleep 0.2
|
||||||
|
Loading…
x
Reference in New Issue
Block a user