diff options
author | Eric Covener <covener@apache.org> | 2014-12-31 16:39:02 +0100 |
---|---|---|
committer | Eric Covener <covener@apache.org> | 2014-12-31 16:39:02 +0100 |
commit | ecf622ac2e3956fcedd6c5d9b97b2bac27a74a22 (patch) | |
tree | d7291924f7948b84636b15dd09801f5f8b0fa644 /support | |
parent | Fix some spelling errors in mod_proxy_fcgi comments. (diff) | |
download | apache2-ecf622ac2e3956fcedd6c5d9b97b2bac27a74a22.tar.xz apache2-ecf622ac2e3956fcedd6c5d9b97b2bac27a74a22.zip |
split-logfile: Fix perl error: 'Can't use string ("example.org:80")
as a symbol ref while "strict refs"'. PR 56329.
Submitted By: Holger Mauermann <mauermann gmail.com>
Committed By: covener
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1648719 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'support')
-rw-r--r-- | support/split-logfile.in | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/support/split-logfile.in b/support/split-logfile.in index 59eda713f9..e5abfc7d25 100644 --- a/support/split-logfile.in +++ b/support/split-logfile.in @@ -29,7 +29,7 @@ use strict; use warnings; -my %is_open = (); +my %log_file = (); while (my $log_line = <STDIN>) { # @@ -54,10 +54,9 @@ while (my $log_line = <STDIN>) { # If the log file for this virtual host isn't opened # yet, do it now. # - if (! $is_open{$vhost}) { - open $vhost, ">>${vhost}.log" + if (! $log_file{$vhost}) { + open $log_file{$vhost}, ">>${vhost}.log" or die ("Can't open ${vhost}.log"); - $is_open{$vhost} = 1; } # # Strip off the first token (which may be null in the @@ -65,6 +64,6 @@ while (my $log_line = <STDIN>) { # record to the current log file. # $log_line =~ s/^\S*\s+//; - printf $vhost "%s", $log_line; + print {$log_file{$vhost}} $log_line; } exit 0; |