This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "IPFire 2.x development tree".
The branch, fifteen has been updated
via 095cbf430f983bdde07187169566997d8285f32d (commit)
via f8b12375c7667d6895ff6d9d2178e0abefbd3b90 (commit)
from 303c90a4c16cbc4f1453b4b1a8fa4c47449830a7 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 095cbf430f983bdde07187169566997d8285f32d
Author: Michael Tremer <michael.tremer(a)ipfire.org>
Date: Sat Sep 7 16:38:23 2013 +0200
Multiple CGI files: Check if BLUE or ORANGE are actually configured.
commit f8b12375c7667d6895ff6d9d2178e0abefbd3b90
Author: Michael Tremer <michael.tremer(a)ipfire.org>
Date: Sat Sep 7 16:23:50 2013 +0200
speed.cgi: Suppress error messages if not connected to the internet.
-----------------------------------------------------------------------
Summary of changes:
config/rootfiles/core/fifteen/filelists/files | 3 +++
html/cgi-bin/netinternal.cgi | 4 ++--
html/cgi-bin/proxy.cgi | 4 ++--
html/cgi-bin/speed.cgi | 5 ++---
html/cgi-bin/vpnmain.cgi | 4 ++--
5 files changed, 11 insertions(+), 9 deletions(-)
Difference in files:
diff --git a/config/rootfiles/core/fifteen/filelists/files b/config/rootfiles/core/fifteen/filelists/files
index 2d4ff42..b97812d 100644
--- a/config/rootfiles/core/fifteen/filelists/files
+++ b/config/rootfiles/core/fifteen/filelists/files
@@ -2,8 +2,11 @@ etc/system-release
etc/issue
etc/rc.d/init.d/network
srv/web/ipfire/cgi-bin/index.cgi
+srv/web/ipfire/cgi-bin/netinternal.cgi
srv/web/ipfire/cgi-bin/ovpnmain.cgi
+srv/web/ipfire/cgi-bin/proxy.cgi
srv/web/ipfire/cgi-bin/upnp.cgi
+srv/web/ipfire/cgi-bin/speed.cgi
srv/web/ipfire/cgi-bin/vpnmain.cgi
var/ipfire/backup/bin/backup.pl
var/ipfire/backup/exclude
diff --git a/html/cgi-bin/netinternal.cgi b/html/cgi-bin/netinternal.cgi
index 60560f3..3f2fb56 100644
--- a/html/cgi-bin/netinternal.cgi
+++ b/html/cgi-bin/netinternal.cgi
@@ -61,8 +61,8 @@ if ( $querry[0] =~ /wireless/ ){
&Header::openbigbox('100%', 'left');
push (@graphs, ($netsettings{'GREEN_DEV'}));
- if ($netsettings{'BLUE_DEV'}) {push (@graphs, ($netsettings{'BLUE_DEV'})); }
- if ($netsettings{'ORANGE_DEV'}) {push (@graphs, ($netsettings{'ORANGE_DEV'})); }
+ if (&Header::blue_used() && $netsettings{'BLUE_DEV'}) {push (@graphs, ($netsettings{'BLUE_DEV'})); }
+ if (&Header::orange_used() && $netsettings{'ORANGE_DEV'}) {push (@graphs, ($netsettings{'ORANGE_DEV'})); }
my @wirelessgraphs = `ls -dA /var/log/rrd/collectd/localhost/wireless* 2>/dev/null`;
foreach (@wirelessgraphs){
diff --git a/html/cgi-bin/proxy.cgi b/html/cgi-bin/proxy.cgi
index bcdc202..97e752e 100644
--- a/html/cgi-bin/proxy.cgi
+++ b/html/cgi-bin/proxy.cgi
@@ -180,8 +180,8 @@ close(FILE);
&General::readhash("${General::swroot}/main/settings", \%mainsettings);
my $green_cidr = &General::ipcidr("$netsettings{'GREEN_NETADDRESS'}\/$netsettings{'GREEN_NETMASK'}");
-my $blue_cidr = "# Blue not defined";
-if ($netsettings{'BLUE_DEV'}) {
+my $blue_cidr = "";
+if (&Header::blue_used() && $netsettings{'BLUE_DEV'}) {
$blue_cidr = &General::ipcidr("$netsettings{'BLUE_NETADDRESS'}\/$netsettings{'BLUE_NETMASK'}");
}
diff --git a/html/cgi-bin/speed.cgi b/html/cgi-bin/speed.cgi
index b714d67..4468abd 100644
--- a/html/cgi-bin/speed.cgi
+++ b/html/cgi-bin/speed.cgi
@@ -36,9 +36,8 @@ foreach $field (@fields) {
}
}
-
-my $interface = `cat /var/ipfire/red/iface`;
-my @data_now = `ip -s link show $interface`;
+my $interface = `cat /var/ipfire/red/iface 2>/dev/null`;
+my @data_now = `ip -s link show $interface 2>/dev/null`;
my $lastline;
my $rxb_now = 0;
diff --git a/html/cgi-bin/vpnmain.cgi b/html/cgi-bin/vpnmain.cgi
index 2fbe480..2d9058d 100644
--- a/html/cgi-bin/vpnmain.cgi
+++ b/html/cgi-bin/vpnmain.cgi
@@ -61,11 +61,11 @@ my %mainsettings = ();
my $green_cidr = &General::ipcidr("$netsettings{'GREEN_NETADDRESS'}/$netsettings{'GREEN_NETMASK'}");
my $blue_cidr = "# Blue not defined";
-if ($netsettings{'BLUE_DEV'}) {
+if (&Header::blue_used() && $netsettings{'BLUE_DEV'}) {
$blue_cidr = &General::ipcidr("$netsettings{'BLUE_NETADDRESS'}/$netsettings{'BLUE_NETMASK'}");
}
my $orange_cidr = "# Orange not defined";
-if ($netsettings{'ORANGE_DEV'}) {
+if (&Header::orange_used() && $netsettings{'ORANGE_DEV'}) {
$orange_cidr = &General::ipcidr("$netsettings{'ORANGE_NETADDRESS'}/$netsettings{'ORANGE_NETMASK'}");
}
hooks/post-receive
--
IPFire 2.x development tree