You are reading the file one line at a time so your regular expression will not work.
This should work:
while ( my $mls = <IN> ) { push @res, $mls if $mls =~ /^message=/ .. $mls =~ /^Message Id/; }
In reply to Re: Multiple Line Regex Not Working
by jwkrahn
in thread Multiple Line Regex Not Working
by ImJustAFriend
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |