Files
FAQ-O-Matic/faqomatic-tmp-pass.patch

34 lines
1013 B
Diff

Index: fom.PL
===================================================================
--- fom.PL.orig
+++ fom.PL
@@ -25,6 +25,10 @@ my $cryptpass = md5_hex($temppass);
# both readable and executable, then we've reopened the window of
# trivial vulnerability for that site.
+open THEPASS, ">fom_pass.txt" or die "Writing \"pass\": $!";
+print THEPASS "$temppass\n";
+close THEPASS;
+
open THECGI, ">fom" or die "Writing \"fom\": $!";
print THECGI "#!$perl -wT\n";
print THECGI "use lib '.'; # for suid installations\n";
@@ -35,9 +39,10 @@ print THECGI <<'EOF';
## Uncomment following two lines (and replace second argument for
## setlocale()) if you want to use some locale, different from default.
-# use POSIX qw(locale_h);
+use POSIX qw(locale_h);
# $ENV{LANG} = 'ja_JP.EUC';
-# POSIX::setlocale(LC_ALL, $ENV{LANG});
+# $ENV{LANG} = 'pl_PL.EUC';
+POSIX::setlocale(LC_ALL, $ENV{LANG});
use locale;
EOF
@@ -71,4 +76,3 @@ You can ignore it.
Press enter to continue.
__EOF__
-my $dummy = <STDIN>;