diff --git a/net/reaim/Makefile b/net/reaim/Makefile index 6c5c4abff..b3fa5d19c 100644 --- a/net/reaim/Makefile +++ b/net/reaim/Makefile @@ -1,5 +1,5 @@ # -# Copyright (C) 2006-2011 OpenWrt.org +# Copyright (C) 2006-2012 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=reaim PKG_VERSION:=0.8 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/reaim diff --git a/net/reaim/files/reaim.init b/net/reaim/files/reaim.init index 39c0cf8d9..d848d9f9b 100644 --- a/net/reaim/files/reaim.init +++ b/net/reaim/files/reaim.init @@ -1,20 +1,20 @@ #!/bin/sh /etc/rc.common -# Copyright (C) 2006-2011 OpenWrt.org +# Copyright (C) 2006-2012 OpenWrt.org START=60 IPT=/usr/sbin/iptables set_rules() { - include /lib/network - scan_interfaces - config_get WAN wan ifname + . /lib/functions/network.sh - [ -z "$WAN" ] && exit - $IPT $1 input_rule -i $WAN -p tcp --dport 1863:1864 -j ACCEPT - $IPT $1 input_rule -i $WAN -p tcp --dport 4443 -j ACCEPT - $IPT $1 input_rule -i $WAN -p tcp --dport 5566 -j ACCEPT - $IPT $1 input_rule -i $WAN -p tcp --dport 40000:40099 -j ACCEPT + local device + network_get_device device wan && { + $IPT $1 input_rule -i $device -p tcp --dport 1863:1864 -j ACCEPT + $IPT $1 input_rule -i $device -p tcp --dport 4443 -j ACCEPT + $IPT $1 input_rule -i $device -p tcp --dport 5566 -j ACCEPT + $IPT $1 input_rule -i $device -p tcp --dport 40000:40099 -j ACCEPT + } } start() {