From: Milton L. Hankins Date: Fri, 9 Jun 2000 12:39:27 +0000 (-0400) Subject: [ID 20000609.002] Text::Wrap::wrap does not handle multiline strings properly X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=e2537f5c973a02cd9a7f1612791af7c8170a2e0e;p=p5sagit%2Fp5-mst-13.2.git [ID 20000609.002] Text::Wrap::wrap does not handle multiline strings properly Message-Id: <39411DBF.A04BB1A@swl.msd.ray.com> (plus update the version "number" of Text::Wrap) p4raw-id: //depot/cfgperl@6278 --- diff --git a/lib/Text/Wrap.pm b/lib/Text/Wrap.pm index 5f95edb..04efe19 100644 --- a/lib/Text/Wrap.pm +++ b/lib/Text/Wrap.pm @@ -6,7 +6,7 @@ require Exporter; @EXPORT = qw(wrap fill); @EXPORT_OK = qw($columns $break $huge); -$VERSION = 98.112902; +$VERSION = 2000.06292219; #GMT use vars qw($VERSION $columns $debug $break $huge); use strict; @@ -33,7 +33,7 @@ sub wrap my $remainder = ""; while ($t !~ /^\s*$/) { - if ($t =~ s/^([^\n]{0,$ll})($break|\Z(?!\n))//xm) { + if ($t =~ s/^([^\n]{0,$ll})($break|\Z(?!\n))//x) { $r .= unexpand($nl . $lead . $1); $remainder = $2; } elsif ($huge eq 'wrap' && $t =~ s/^([^\n]{$ll})//) {