public inbox for ipfire-scm@lists.ipfire.org
 help / color / mirror / Atom feed
From: git@ipfire.org
To: ipfire-scm@lists.ipfire.org
Subject: [git.ipfire.org] IPFire 2.x development tree branch, fifteen, updated. 095cbf430f983bdde07187169566997d8285f32d
Date: Sat, 07 Sep 2013 16:41:33 +0200	[thread overview]
Message-ID: <20130907144133.EE6DF20F97@argus.ipfire.org> (raw)

[-- Attachment #1: Type: text/plain, Size: 4955 bytes --]

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

                 reply	other threads:[~2013-09-07 14:41 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130907144133.EE6DF20F97@argus.ipfire.org \
    --to=git@ipfire.org \
    --cc=ipfire-scm@lists.ipfire.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox