eldy / AWStats

AWStats Log Analyzer project (official sources)
https://www.awstats.org
361 stars 119 forks source link

After upgrading the OS we awstats throws an error about CleanFromTags #229

Open alexanderharm opened 1 year ago

alexanderharm commented 1 year ago

Describe the bug Updating the database fails with Undefined subroutine &main::CleanFromTags called at /server/service/awstats/wwwroot/cgi-bin/awstats.pl line 3912, <HISTORY> line 141199.

To Reproduce Run awstats to update database.

Expected behavior No error message.

Additional context The error occurs under latest 7.9. 7.8 seems to work fine.

irb commented 1 year ago

Same here. It also leaves behind a lockfile in /tmp. Downgrading to 7.8 resolved the problem.

bennettyip commented 6 months ago

In /tools/ebmin/awstats/awstats-lib.pl file, there is a CleanFromTags subroutine.

sub CleanFromTags { my $stringtoclean=shift; $stringtoclean =~ s/$regclean1/ /g; # Replace or with space $stringtoclean =~ s/$regclean2//g; # Remove return $stringtoclean; }

I copyied and pasted the subroutine into the awstats.pl file. It could run without the error.