chiark / gitweb /
unfolding: do not introduce additional lwsp
[modbot-urcm.git] / stump / bin / submission.pl
index fdd5acc2ec4c088acba73cdfb770a2cd4569426f..d19c3ba9eaa08d6f64a8d94964b3d759889dd2ca 100755 (executable)
@@ -348,13 +348,15 @@ sub readMessage {
        # In these cases, keep that in $readahead for now,
        # and process the previous header, which is in $_.
        # But, first, a wrinkle ...
-       push @unfolded, (m/^[^:]+:/ ? $& : '????')
-           if s/\n(?=.)/ /g;
-       if (length $_ > 505) { #wtf
-         $_ = substr($_, 0, 500);
-         $_ =~ s/\n?$/\n/;
-         $readahead = $_;
-         $_ = $warning->("Next header truncated!");
+       if (!m/^(?:References):/i) {
+         push @unfolded, (m/^[^:]+:/ ? $& : '????')
+           if s/\n(?=.)//g;
+         if (length $_ > 505) { #wtf
+           $_ = substr($_, 0, 500);
+           $_ =~ s/\n?$/\n/;
+           $readahead = $_;
+           $_ = $warning->("Next header truncated!");
+         }
        }
       } else {
        # $_ is empty line at end of headers