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, next has been updated via e353470a8c8d64543960bdf4d20eb86725c939d5 (commit) via a1468f66f0c5f52428ed17bd809a18c10b260cee (commit) from 5428eeeeaac1ecacbec2aecb9279cccd29e9c47d (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 e353470a8c8d64543960bdf4d20eb86725c939d5 Author: Michael Tremer michael.tremer@ipfire.org Date: Wed Jun 17 14:02:05 2015 +0200
dhcp.cgi: Count up key when skippingh search entries
This caused a bug that when the user wanted to edit one of the static leases and clicked on the edit icon that an other entry opened up for editing.
Signed-off-by: Michael Tremer michael.tremer@ipfire.org
commit a1468f66f0c5f52428ed17bd809a18c10b260cee Author: Michael Tremer michael.tremer@ipfire.org Date: Wed Jun 17 14:01:40 2015 +0200
dhcp.cgi: Never save the search query
Signed-off-by: Michael Tremer michael.tremer@ipfire.org
-----------------------------------------------------------------------
Summary of changes: html/cgi-bin/dhcp.cgi | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-)
Difference in files: diff --git a/html/cgi-bin/dhcp.cgi b/html/cgi-bin/dhcp.cgi index dd48d58..971c51e 100644 --- a/html/cgi-bin/dhcp.cgi +++ b/html/cgi-bin/dhcp.cgi @@ -244,7 +244,7 @@ if ($dhcpsettings{'ACTION'} eq $Lang::tr{'save'}) { } # enabled }#loop interface verify
- map (delete ($dhcpsettings{$_}) ,@nosaved,'ACTION','KEY1','KEY2'); # Must not be saved + map (delete ($dhcpsettings{$_}) ,@nosaved,'ACTION','KEY1','KEY2','q'); # Must not be saved &General::writehash($setting, %dhcpsettings); # Save good settings $dhcpsettings{'ACTION'} = $Lang::tr{'save'}; # create an 'ACTION' map ($dhcpsettings{$_} = '',@nosaved,'KEY1','KEY2'); # and reinit vars to empty @@ -267,7 +267,7 @@ if ($ENV{'QUERY_STRING'} =~ /^FETHER|^FIPADDR/ ) { $newsort.=$Rev; } $dhcpsettings{'SORT_FLEASELIST'}=$newsort; - map (delete ($dhcpsettings{$_}) ,@nosaved,'ACTION','KEY1','KEY2'); # Must never be saved + map (delete ($dhcpsettings{$_}) ,@nosaved,'ACTION','KEY1','KEY2', 'q'); # Must never be saved &General::writehash($setting, %dhcpsettings); &sortcurrent2; $dhcpsettings{'ACTION'} = 'SORT'; # create an 'ACTION' @@ -942,7 +942,10 @@ foreach my $line (@current2) {
# Skip all entries that do not match the search query if ($search_query ne "") { - next if (!grep(/$search_query/, @temp)); + if (!grep(/$search_query/, @temp)) { + $key++; + next; + } }
if ($dhcpsettings{'KEY2'} eq $key) {
hooks/post-receive -- IPFire 2.x development tree