X-Git-Url: http://git.ipfire.org/?a=blobdiff_plain;f=html%2Fcgi-bin%2Fupdatexlrator.cgi;h=df77a86afdb2e690464d0b3d23b96821a7631bca;hb=f69446d2fa5fc519c223faeb9506842e191e46ca;hp=04b7b8ee68b7020286b11e346b0bcdab5ee47e32;hpb=a4883c68c14fbf73474cbcf050d3d99acf5b2cfb;p=people%2Fteissler%2Fipfire-2.x.git diff --git a/html/cgi-bin/updatexlrator.cgi b/html/cgi-bin/updatexlrator.cgi index 04b7b8ee6..df77a86af 100644 --- a/html/cgi-bin/updatexlrator.cgi +++ b/html/cgi-bin/updatexlrator.cgi @@ -27,6 +27,11 @@ # along with this program. If not, see . # # # ############################################################################### +# +# Changelog: +# 2012-10-27: nightshift - Bugfix regarding showing wrong vendor icon while Download of new Updates +# 2012-10-27: nightshift - Optimizing logic of check for vendor icons +# use strict; @@ -75,6 +80,7 @@ my @vendors=(); my %vendorstats=(); my $repository = "/var/updatecache/"; +my $webhome = "/srv/web/ipfire/html"; my $hintcolour = '#FFFFCC'; my $colourgray = '#808080'; @@ -549,46 +555,23 @@ END print "$Lang::tr{ \n"; } - print "\t\t "; - if ($vendorid =~ /^Adobe$/i) - { - print "Adobe \n"; - } elsif ($vendorid =~ /^Microsoft$/i) - { - print "Microsoft \n"; - } elsif ($vendorid =~ /^Symantec$/i) - { - print "Symantec \n"; - } elsif ($vendorid =~ /^Linux$/i) - { - print "Linux \n"; - } elsif ($vendorid =~ /^TrendMicro$/i) - { - print "Trend Micro \n"; - } elsif ($vendorid =~ /^Apple$/i) - { - print "Apple \n"; - } elsif ($vendorid =~ /^Avast$/i) - { - print "Avast \n"; - } else - { - if (-e "/home/httpd/html/images/updbooster/updxl-src-" . $vendorid . ".gif") - { - print "" . ucfirst $vendorid . " \n"; - } else { - print "" . ucfirst $vendorid . " \n"; - } - } + print "\t\t "; - $shortname = substr($updatefile,rindex($updatefile,"/")+1); - $shortname =~ s/(.*)_[\da-f]*(\.(exe|cab|psf)$)/$1_*$2/i; + if (($vendorid ne '') && (-e "$webhome/images/updbooster/updxl-src-$vendorid.gif")) + { + print "" . ucfirst $vendorid . " \n"; + } else { + print "" . ucfirst $vendorid . " \n"; + } - $filesize = $dlinfo{'REMOTESIZE'}; - 1 while $filesize =~ s/^(-?\d+)(\d{3})/$1.$2/; - $dlinfo{'VENDORID'}=ucfirst $vendorid; + $shortname = substr($updatefile,rindex($updatefile,"/")+1); + $shortname =~ s/(.*)_[\da-f]*(\.(exe|cab|psf)$)/$1_*$2/i; - print < $dlinfo{'VENDORID'}  $shortname  $filesize  @@ -1362,7 +1345,7 @@ sub printlegendicons $Lang::tr{ $Lang::tr{'updxlrtr last checkup'}   - $Lang::tr{ + $Lang::tr{ $Lang::tr{'updxlrtr remove file'}