[Rt-commit] r4400 - in rt/branches/QUEBEC-EXPERIMENTAL: .

alexmv at bestpractical.com alexmv at bestpractical.com
Wed Jan 18 16:35:37 EST 2006


Author: alexmv
Date: Wed Jan 18 16:35:37 2006
New Revision: 4400

Modified:
   rt/branches/QUEBEC-EXPERIMENTAL/   (props changed)
   rt/branches/QUEBEC-EXPERIMENTAL/lib/RT/Action/CreateTickets.pm

Log:
 r8683 at zoq-fot-pik:  chmrr | 2006-01-18 16:34:42 -0500
  * Correctly deal with 0-length field values; now passes test suite
    again.  Mea culpa.


Modified: rt/branches/QUEBEC-EXPERIMENTAL/lib/RT/Action/CreateTickets.pm
==============================================================================
--- rt/branches/QUEBEC-EXPERIMENTAL/lib/RT/Action/CreateTickets.pm	(original)
+++ rt/branches/QUEBEC-EXPERIMENTAL/lib/RT/Action/CreateTickets.pm	Wed Jan 18 16:35:37 2006
@@ -1048,7 +1048,7 @@
         my $template_id;
 
       COLUMN:
-        while ($args{'Content'} =~ s/^($justquoted|.+?)($delimiter_re|$)//smix) {
+        while (length $args{'Content'} and $args{'Content'} =~ s/^($justquoted|.*?)($delimiter_re|$)//smix) {
             my $EOL = not $2;
             # If it's the first field, it must be a ticket id. 
             if ( $i == 0 ) {
@@ -1070,7 +1070,6 @@
                 }
             } else {
                 my $value = $1;
-                $value = '' if ( $value =~ /^$delimiter$/ );
                 if ( $value =~ /^$RE{delimited}{-delim=>qq{\'\"}}$/ ) {
                     substr( $value, 0,  1 ) = "";
                     substr( $value, -1, 1 ) = "";


More information about the Rt-commit mailing list