integrate cfgperl changes#6220..6222 into mainline
[p5sagit/p5-mst-13.2.git] / pod / buildtoc
index 21fee31..58bfc54 100644 (file)
@@ -177,10 +177,11 @@ sub podset {
            $inhead2 = 1;
            output $_; nl(); next;
        }
-       if (s/^=item ([^=].*)\n/$1/) {
+       if (s/^=item ([^=].*)/$1/) {
            next if $pod eq 'perldiag';
            s/^\s*\*\s*$// && next;
            s/^\s*\*\s*//;
+           s/\n/ /g;
            s/\s+$//;
            next if /^[\d.]+$/;
            next if $pod eq 'perlmodlib' && /^ftp:/;