aboutsummaryrefslogtreecommitdiffstats
path: root/doc/dfilter2pod.pl
diff options
context:
space:
mode:
authorOlivier Biot <obiot.ethereal@gmail.com>2004-04-28 17:50:02 +0000
committerOlivier Biot <obiot.ethereal@gmail.com>2004-04-28 17:50:02 +0000
commit306ac8b99463f50383dce49e806841616bfd72fe (patch)
tree1dc030ecc04249afba03b555d71fd9b8bd9ea4b5 /doc/dfilter2pod.pl
parentdb200f55ccbe3d5ca8d13e109d8413c115341f95 (diff)
When building the Ethereal documentation on MSVC++/cygwin the cygwin perl
will not swallow the '\r\n' line end sequence when invoking chomp(), but instead the '\r' character will remain. For this reason, chomp() cannot be used and global removal of '\r' and '\n' characters must be used instead, like in: $_ =~ s/[\r\n]//g; svn path=/trunk/; revision=10719
Diffstat (limited to 'doc/dfilter2pod.pl')
-rwxr-xr-xdoc/dfilter2pod.pl6
1 files changed, 4 insertions, 2 deletions
diff --git a/doc/dfilter2pod.pl b/doc/dfilter2pod.pl
index 333bc8f782..4e080bdd14 100755
--- a/doc/dfilter2pod.pl
+++ b/doc/dfilter2pod.pl
@@ -9,7 +9,7 @@
# will be replaced by the pod-formatted glossary
# STDOUT is the output
#
-# $Id: dfilter2pod.pl,v 1.4 2002/12/19 02:58:45 guy Exp $
+# $Id: dfilter2pod.pl,v 1.5 2004/04/28 17:50:02 obiot Exp $
%ftenum_names = (
'FT_NONE', 'No value',
@@ -44,7 +44,9 @@ while (<STDIN>) {
next unless (/^([PF])/);
$record_type = $1;
- chomp($_);
+ # Strip the line from its line-end sequence
+ # chomp($_) won't work on Win32/CygWin as it leaves the '\r' character.
+ $_ =~ s/[\r\n]//g;
# Store protocol information
if ($record_type eq 'P') {