From: martin f. krafft Date: Wed, 15 Feb 2017 21:20:06 +0000 (+0100) Subject: Switch to 3-arg open calls X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=d707da591a371427bf67e9eb1a7a2993c5730c55;p=irssi-scripts.irssi.org.git Switch to 3-arg open calls Signed-off-by: martin f. krafft --- diff --git a/scripts/ctrlact.pl b/scripts/ctrlact.pl index c35a2c4..534b00a 100644 --- a/scripts/ctrlact.pl +++ b/scripts/ctrlact.pl @@ -361,10 +361,10 @@ sub get_mappings_fh { my ($filename) = @_; my $fh; if (-e $filename) { - open($fh, $filename) || croak "Cannot open mappings file: $!"; + open($fh, '<', $filename) || croak "Cannot open mappings file: $!"; } else { - open($fh, "+>$filename") || croak "Cannot create mappings file: $!"; + open($fh, '+>', $filename) || croak "Cannot create mappings file: $!"; my $ftw = from_data_level($fallback_window_threshold); my $ftc = from_data_level($fallback_channel_threshold);