mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-19 03:43:29 +00:00
luci ssr plus:disable UDP multithreading for kernel < 4.6
This commit is contained in:
parent
e52912fb31
commit
cf38534db4
@ -2,7 +2,7 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=luci-app-ssr-plus
|
||||
PKG_VERSION:=1
|
||||
PKG_RELEASE:=76
|
||||
PKG_RELEASE:=77
|
||||
|
||||
PKG_CONFIG_DEPENDS:= CONFIG_PACKAGE_$(PKG_NAME)_INCLUDE_Shadowsocks \
|
||||
CONFIG_PACKAGE_$(PKG_NAME)_INCLUDE_V2ray \
|
||||
|
@ -303,21 +303,6 @@ start_redir() {
|
||||
fi
|
||||
|
||||
redir_tcp=1
|
||||
|
||||
if [ "$ARG_UDP" = "-u" ]; then
|
||||
redir_udp=1
|
||||
if [ "$stype" == "ss" -o "$stype" == "ssr" ] ;then
|
||||
local last_config_file=$CONFIG_FILE
|
||||
for i in $(seq 1 $threads)
|
||||
do
|
||||
$sscmd -c $CONFIG_FILE $ARG_OTA -u -f /var/run/ssr-retcp-ssr-reudp_$i.pid >/dev/null 2>&1
|
||||
done
|
||||
elif [ "$utype" == "v2ray" ] ; then
|
||||
lua /usr/share/shadowsocksr/genv2config.lua $GLOBAL_SERVER 'tcp,udp' $(uci_get_by_name $GLOBAL_SERVER local_port) > /var/etc/v2-ssr-retcp-ssr-reudp.json
|
||||
$sscmd -config /var/etc/v2-ssr-retcp-ssr-reudp.json >/dev/null 2>&1 &
|
||||
fi
|
||||
else
|
||||
|
||||
if [ "$stype" == "ss" -o "$stype" == "ssr" ] ;then
|
||||
local last_config_file=$CONFIG_FILE
|
||||
local pid_file="/var/run/ssr-retcp.pid"
|
||||
@ -340,17 +325,12 @@ start_redir() {
|
||||
gen_config_file $UDP_RELAY_SERVER 1
|
||||
last_config_file=$CONFIG_UDP_FILE
|
||||
pid_file="/var/run/ssr-reudp.pid"
|
||||
for i in $(seq 1 $threads)
|
||||
do
|
||||
$ucmd -c $last_config_file $ARG_OTA -U -f /var/run/ssr-reudp_$i.pid >/dev/null 2>&1
|
||||
done
|
||||
$ucmd -c $last_config_file $ARG_OTA -U -f /var/run/ssr-reudp.pid >/dev/null 2>&1
|
||||
elif [ "$utype" == "v2ray" ] ; then
|
||||
lua /usr/share/shadowsocksr/genv2config.lua $UDP_RELAY_SERVER udp $(uci_get_by_name $UDP_RELAY_SERVER local_port) > /var/etc/v2-ssr-reudp.json
|
||||
$ucmd -config /var/etc/v2-ssr-reudp.json >/dev/null 2>&1 &
|
||||
fi
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user