summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKurt Zenker <kz@openoffice.org>2007-10-09 14:02:49 +0000
committerKurt Zenker <kz@openoffice.org>2007-10-09 14:02:49 +0000
commitcda3af93a8be732f2a123ee91b0651c840cace46 (patch)
tree0122ac634980b0e768be62ec0f1161e03683375e
parenta7ab229ff40aefcd4a756e66bc16dd1336999adb (diff)
INTEGRATION: CWS hr47 (1.2.32); FILE MERGED
2007/10/05 11:57:12 hr 1.2.32.1: #i82172#: handle any combination of line~end-conventions/OS in administrative files and .cvspass
-rw-r--r--solenv/bin/modules/PCVSLib/lib/PCVSLib/Credentials.pm5
-rw-r--r--solenv/bin/modules/PCVSLib/lib/PCVSLib/Directory.pm12
2 files changed, 9 insertions, 8 deletions
diff --git a/solenv/bin/modules/PCVSLib/lib/PCVSLib/Credentials.pm b/solenv/bin/modules/PCVSLib/lib/PCVSLib/Credentials.pm
index c85bdc1db9c5..05af92e81d5f 100644
--- a/solenv/bin/modules/PCVSLib/lib/PCVSLib/Credentials.pm
+++ b/solenv/bin/modules/PCVSLib/lib/PCVSLib/Credentials.pm
@@ -4,9 +4,9 @@
#
# $RCSfile: Credentials.pm,v $
#
-# $Revision: 1.2 $
+# $Revision: 1.3 $
#
-# last change: $Author: vg $ $Date: 2007-08-27 13:33:43 $
+# last change: $Author: kz $ $Date: 2007-10-09 15:02:36 $
#
# The Contents of this file are made available subject to
# the terms of GNU Lesser General Public License Version 2.1.
@@ -123,6 +123,7 @@ sub parse_passfile
croak("PCVSLIB::Credentials::parse_passfile(): can't open CVS password file: '$passfile': $!");
}
while(<$fh>) {
+ tr/\r\n//d;
if ( /^\/1 (:pserver:\S+) (\S.*)$/ ) {
# new style .cvspass entries
$self->{passwords_}->{$1} = $2;
diff --git a/solenv/bin/modules/PCVSLib/lib/PCVSLib/Directory.pm b/solenv/bin/modules/PCVSLib/lib/PCVSLib/Directory.pm
index 373bbdbe7ca8..f5704e7b3c5c 100644
--- a/solenv/bin/modules/PCVSLib/lib/PCVSLib/Directory.pm
+++ b/solenv/bin/modules/PCVSLib/lib/PCVSLib/Directory.pm
@@ -4,9 +4,9 @@
#
# $RCSfile: Directory.pm,v $
#
-# $Revision: 1.2 $
+# $Revision: 1.3 $
#
-# last change: $Author: vg $ $Date: 2007-08-27 13:33:54 $
+# last change: $Author: kz $ $Date: 2007-10-09 15:02:49 $
#
# The Contents of this file are made available subject to
# the terms of GNU Lesser General Public License Version 2.1.
@@ -268,7 +268,7 @@ sub read_entries_file_ {
my $entries_fh = $self->open_admin_file_("Entries", 0);
$self->{is_leaf} = 0;
while (my $line = <$entries_fh>) {
- chomp($line);
+ $line=~tr/\r\n//d;
if ( $line =~ /^D$/ ) {
$self->{is_leaf} = 1;
next;
@@ -285,7 +285,7 @@ sub read_root_file_ {
my $root_fh = $self->open_admin_file_("Root", 0);
my $root = <$root_fh>;
- chomp($root);
+ $root=~tr/\r\n//d;
$self->{root} = PCVSLib::Root->new($root);
$root_fh->close();
@@ -296,7 +296,7 @@ sub read_repository_file_ {
my $repository_fh = $self->open_admin_file_("Repository", 0);
my $line = <$repository_fh>;
- chomp($line);
+ $line=~tr/\r\n//d;
$self->{repository} = $line;
$repository_fh->close();
}
@@ -308,7 +308,7 @@ sub read_tag_file_ {
if ( -e $tag_path ) {
my $tag_fh = $self->open_admin_file_("Tag", 0);
$self->{tag} = <$tag_fh>;
- chomp($self->{tag});
+ $self->{tag}=~tr/\r\n//d;
$tag_fh->close();
}
else {