summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
e314c34)
Reviewed-by: Richard Levitte <levitte@openssl.org>
close OUT;
# ask user for existing CA certificate
print "CA certificate filename (or enter to create)\n";
close OUT;
# ask user for existing CA certificate
print "CA certificate filename (or enter to create)\n";
- $FILE = <STDIN>;
- $FILE = s|\R$|| if $FILE;
- if ($FILE) {
+ $FILE = "" unless defined($FILE = <STDIN>);
+ $FILE =~ s{\R$}{};
+ if ($FILE ne "") {
copy_pemfile($FILE,"${CATOP}/private/$CAKEY", "PRIVATE");
copy_pemfile($FILE,"${CATOP}/$CACERT", "CERTIFICATE");
} else {
copy_pemfile($FILE,"${CATOP}/private/$CAKEY", "PRIVATE");
copy_pemfile($FILE,"${CATOP}/$CACERT", "CERTIFICATE");
} else {
+while(defined($line=<>)) {
$line =~ s|\R$||; # Better chomp
$line =~ s|\R$||; # Better chomp
{
$b=$`; # Keep what is before the backslash
$o.=$b." ";
{
$b=$`; # Keep what is before the backslash
$o.=$b." ";
- $b=<>;
- $b =~ s|\R$||; # Better chomp
+ $b = "" unless defined($b = <>);
+ $b =~ s{\R$}{};
-$pwd=`pwd`; $pwd =~ s|\R$||;
+($pwd=`pwd`) =~ s{\R$}{};
if ($sym{'TOP'} eq ".")
{
if ($sym{'TOP'} eq ".")
{
{
open (IN, "util/fipslib_path.txt") || fipslib_error();
$fipslibdir = <IN>;
{
open (IN, "util/fipslib_path.txt") || fipslib_error();
$fipslibdir = <IN>;
- $fipslibdir =~ s|\R$||;
+ $fipslibdir = "" unless defined($fipslibdir);
+ $fipslibdir =~ s{\R$}{};
+ fipslib_error() if ($fipslibdir eq "");
}
fips_check_files($fipslibdir,
"fipscanister.lib", "fipscanister.lib.sha1",
}
fips_check_files($fipslibdir,
"fipscanister.lib", "fipscanister.lib.sha1",
- $b=<IN>;
- $b =~ s|\R$||;
+ $b = "" unless defined($b = <IN>);
+ $b =~ s{\R$}{};