From 56add57f296e5b9e8e9ec4a739f872109f20077c Mon Sep 17 00:00:00 2001 From: florian Date: Wed, 8 Feb 2006 14:08:21 +0000 Subject: Removed init script as there is an hotplug one, check whether user configuration directive is properly set, change the numbering to 10 rather than 15 git-svn-id: svn://svn.openwrt.org/openwrt/trunk/openwrt@3189 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- package/ez-ipupdate/files/ez-ipupdate.hotplug | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'package/ez-ipupdate/files') diff --git a/package/ez-ipupdate/files/ez-ipupdate.hotplug b/package/ez-ipupdate/files/ez-ipupdate.hotplug index 3f27c140a..56a054b4a 100644 --- a/package/ez-ipupdate/files/ez-ipupdate.hotplug +++ b/package/ez-ipupdate/files/ez-ipupdate.hotplug @@ -1 +1,6 @@ -[ "$ACTION" = "ifup" -a "$INTERFACE" = "wan" ] && /usr/sbin/ez-ipupdate -c /etc/ez-ipupdate.conf & +PGM=ez-ipupdate +[ "$ACTION" = "ifup" -a "$INTERFACE" = "wan" ] && { + [ -e /etc/$PGM.conf ] && { + [ -n $(grep "user=" /etc/$PGM.conf | cut -d= -f2 | cut -d: -f1) ] && [ -n $(grep "user=" /etc/$PGM.conf | cut -d= -f2 | cut -d: -f2) ] && /usr/sbin/$PGM -c /etc/$PGM.conf & + } +} -- cgit v1.2.3