From: eldy <> Date: Wed, 23 Oct 2002 17:11:54 +0000 (+0000) Subject: Fixed pb when Timezone was "+0" insteadof "0". X-Git-Tag: AWSTATS_5_1_RELEASE~8 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c1c67364bc433c013b8d7ba992a2edc13ac6f9db;p=thirdparty%2FAWStats.git Fixed pb when Timezone was "+0" insteadof "0". --- diff --git a/wwwroot/cgi-bin/plugins/timezone.pm b/wwwroot/cgi-bin/plugins/timezone.pm index 1eb64ccf..aaf806a3 100644 --- a/wwwroot/cgi-bin/plugins/timezone.pm +++ b/wwwroot/cgi-bin/plugins/timezone.pm @@ -43,8 +43,8 @@ sub Init_timezone { # <----- # YOU CAN ENTER HERE CODE TO INIT PLUGIN GLOBAL VARIABLES - if (! $InitParams) { return "Error: Disable plugin if TimeZone is 0 (Plugin useless)"; } # We do not need this plugin if TZ=0 - $PluginTimeZoneSeconds=($InitParams*3600); + if (! $InitParams || int($InitParams) == 0) { return "Error: Disable plugin if TimeZone is 0 (Plugin useless)"; } # We do not need this plugin if TZ=0 + $PluginTimeZoneSeconds=(int($InitParams)*3600); # -----> my $checkversion=&Check_Plugin_Version($PluginNeedAWStatsVersion);