} elsif ($style eq 'suffixes') {
my $suffix;
if (-e $file && -r $file) {
- $/ = "\n";
+ local $/ = "\n";
@ARGV = ($file);
srand;
rand($.) < 1 && ($suffix = switch_parse_special($_, $channel)) while <>;
error("Could not read dejunk activity data from $fn: $!");
return;
}
- $/ = undef;
+ local $/;
my $file_contents = <$fh>;
eval {
my $data = eval $file_contents;
my $paddr = sockaddr_in($listen_port, $iaddr);
socket(S, PF_INET, SOCK_DGRAM, $proto) || die "socket: $!\n";
bind(S, $paddr) || die "bind: $!\n";
-$| = 1;
# Set input and signals etc. irssi related stuff.
Irssi::input_add(fileno(S), INPUT_READ, "run_bot", "");
my $next_channels = 0;
my $channels;
- $. = "\n";
+ local $/ = "\n";
my $f = gensym;
if (!open($f, "<", "$cache_path/$nick")) {
Irssi::print("Couldn't open file $cache_path/$nick: $!", MSGLEVEL_CLIENTERROR);
my @colors = (15, 12, 03, 06, 05, 07, 14);
my @articles = ();
-$| = 1;
-
Irssi::command_bind article => sub {
my $usage = '/article [-s <server>] [-p <port>] [-P <password> -U <login>] [-l <group> <count>] [-a] [-L <index>] <Message-ID>';
# and then we read the userfile.
# apparently Irssi resets $/, so we set it here.
- $/ = "\n";
+ local $/ = "\n";
while( my $line = <XUSERS>) {
if( $line !~ /^(#|\s*$)/ ) {
my ($nick, $ircnet, $password) =
# and then we read the channelfile.
# apparently Irssi resets $/, so we set it here.
- $/ = "\n";
+ local $/ = "\n";
while( my $line = <NICKCHANS>) {
if( $line !~ /^(#|\s*$)/ ) {
my ($channel, $ircnet) =