aboutsummaryrefslogtreecommitdiffstats
path: root/packages/miniupnpd/miniupnpd.inc
diff options
context:
space:
mode:
authorRyan Wagoner <rsw686@pfsense.org>2006-12-15 15:27:14 +0000
committerRyan Wagoner <rsw686@pfsense.org>2006-12-15 15:27:14 +0000
commit40bc7cb32abaa8bd04862658cce48a0453704ca7 (patch)
treed9d8d485d8135f4cfd5ec429bf95a8671cc6e219 /packages/miniupnpd/miniupnpd.inc
parenta0b03074e579aa7c2033a50af331acfc7672869a (diff)
downloadpfsense-packages-40bc7cb32abaa8bd04862658cce48a0453704ca7.tar.gz
pfsense-packages-40bc7cb32abaa8bd04862658cce48a0453704ca7.tar.bz2
pfsense-packages-40bc7cb32abaa8bd04862658cce48a0453704ca7.zip
add enable checkbox, format menu name to MiniUPnP
Diffstat (limited to 'packages/miniupnpd/miniupnpd.inc')
-rw-r--r--packages/miniupnpd/miniupnpd.inc12
1 files changed, 8 insertions, 4 deletions
diff --git a/packages/miniupnpd/miniupnpd.inc b/packages/miniupnpd/miniupnpd.inc
index a8721c8b..fdee5a9e 100644
--- a/packages/miniupnpd/miniupnpd.inc
+++ b/packages/miniupnpd/miniupnpd.inc
@@ -2,7 +2,7 @@
require_once("config.inc");
require_once("functions.inc");
- /* Miniupnpd */
+ /* MiniUPnP */
function upnp_notice ($msg) { syslog(LOG_NOTICE, "miniupnpd: $msg"); return; }
function upnp_warn ($msg) { syslog(LOG_WARNING, "miniupnpd: $msg"); return; }
@@ -65,8 +65,8 @@
config_lock();
- /* since config is written before this file invoked we don't need to read post data */
- if(upnp_config("iface_array"))
+ /* since config is written before this file invoked we don't need to read post data */
+ if(upnp_config("enable") && upnp_config("iface_array"))
$iface_array = explode(",",upnp_config("iface_array"));
if($iface_array) {
@@ -170,7 +170,11 @@ EOD;
/* lets stop the service and remove the rc file */
if(file_exists("/usr/local/etc/rc.d/miniupnpd.sh")) {
- upnp_notice("Stopping service, no interfaces selected");
+ if(!upnp_config("enable"))
+ upnp_notice("Stopping service, miniupnpd disabled");
+ else
+ upnp_notice("Stopping service, no interfaces selected");
+
stop_service("miniupnpd");
conf_mount_rw();