mhonarc-commits
[Top] [All Lists]

CVS: mhonarc/MHonArc/lib mhdb.pl,2.31,2.32 mhfile.pl,2.9,2.10 mhinit.pl,2.4...

2003-02-21 21:40:31
Update of /cvsroot/mhonarc/mhonarc/MHonArc/lib
In directory subversions:/tmp/cvs-serv13030/lib

Modified Files:
	mhdb.pl mhfile.pl mhinit.pl mhopt.pl mhrcfile.pl 
Log Message:
* Added FASTTEMPFILES resource which causes MHonArc to use
  non-random temporary files.  This is less secure, but provides
  a little bit of speed improvement.
* BUG FIX #2628: Typo in mhrcfile.pl.


Index: mhdb.pl
===================================================================
RCS file: /cvsroot/mhonarc/mhonarc/MHonArc/lib/mhdb.pl,v
retrieving revision 2.31
retrieving revision 2.32
diff -C2 -r2.31 -r2.32
*** mhdb.pl	4 Feb 2003 23:31:19 -0000	2.31
--- mhdb.pl	22 Feb 2003 04:40:11 -0000	2.32
***************
*** 156,159 ****
--- 156,160 ----
  print_var($db,'ExpireDate',     \$ExpireDate);
  print_var($db,'ExpireTime',     \$ExpireTime);
+ print_var($db,'FastTempFiles',  \$FastTempFiles);
  print_var($db,'FROM',           \$FROM);
  print_var($db,'GMTDateFmt',     \$GMTDateFmt);

Index: mhfile.pl
===================================================================
RCS file: /cvsroot/mhonarc/mhonarc/MHonArc/lib/mhfile.pl,v
retrieving revision 2.9
retrieving revision 2.10
diff -C2 -r2.9 -r2.10
*** mhfile.pl	24 Nov 2002 04:15:12 -0000	2.9
--- mhfile.pl	22 Feb 2003 04:40:11 -0000	2.10
***************
*** 169,172 ****
--- 169,181 ----
  
      MKTEMP: {
+ 	if ($FastTempFiles) {
+ 	    $handle = gensym;
+ 	    $tmpfile = join($DIRSEP, $dir, $template.$$);
+ 	    if (!sysopen($handle, $tmpfile,
+ 			 (O_WRONLY|O_EXCL|O_CREAT), 0600)) {
+ 		die qq/ERROR: Unable to create temp file "$tmpfile": $!\n/;
+ 	    }
+ 	    last MKTEMP;
+ 	}
  	if ($_have_File_Temp) {
  	    ($handle, $tmpfile) =

Index: mhinit.pl
===================================================================
RCS file: /cvsroot/mhonarc/mhonarc/MHonArc/lib/mhinit.pl,v
retrieving revision 2.46
retrieving revision 2.47
diff -C2 -r2.46 -r2.47
*** mhinit.pl	4 Feb 2003 23:31:19 -0000	2.46
--- mhinit.pl	22 Feb 2003 04:40:11 -0000	2.47
***************
*** 398,401 ****
--- 398,404 ----
  $UsingLASTPG = defined($ENV{'M2H_USINGLASTPG'}) ? $ENV{'M2H_USINGLASTPG'} : 1;
  
+ $FastTempFiles = defined($ENV{'M2H_FASTTEMPFILES'}) ?
+ 			 $ENV{'M2H_FASTTEMPFILES'} : 0;
+ 
  @FMTFILE     = defined($ENV{'M2H_RCFILE'}) ?
  		    ($ENV{'M2H_RCFILE'}) : ();

Index: mhopt.pl
===================================================================
RCS file: /cvsroot/mhonarc/mhonarc/MHonArc/lib/mhopt.pl,v
retrieving revision 2.51
retrieving revision 2.52
diff -C2 -r2.51 -r2.52
*** mhopt.pl	19 Jan 2003 01:35:59 -0000	2.51
--- mhopt.pl	22 Feb 2003 04:40:11 -0000	2.52
***************
*** 63,66 ****
--- 63,67 ----
  	'expiredate=s',	# Message cut-off date
  	'expireage=i',	# Time in seconds from current if message expires
+ 	'fasttempfiles',# Do not use random filenames for temporary files
  	'fileperms=i',	# Octal permission to create files
  	'folrefs',	# Print links to explicit follow-ups/references
***************
*** 115,118 ****
--- 116,121 ----
  			# Do not decode 1522 encoded data in message headers
  	'nodoc',	# Do not print link to doc at end of index page
+ 	'nofasttempfiles',
+ 			# Use random filenames for temporary files
  	'nofolrefs',	# Do not print links to explicit follow-ups/references
  	'nogzipfiles',	# Do not Gzip files
***************
*** 580,583 ****
--- 583,588 ----
      $CheckNoArchive = 1  if $opt{'checknoarchive'};
      $CheckNoArchive = 0  if $opt{'nochecknoarchive'};
+     $FastTempFiles  = 1  if $opt{'fasttempfiles'};
+     $FastTempFiles  = 0  if $opt{'nofasttempfiles'};
      $POSIXstrftime  = 1  if $opt{'posixstrftime'};
      $POSIXstrftime  = 0  if $opt{'noposixstrftime'};

Index: mhrcfile.pl
===================================================================
RCS file: /cvsroot/mhonarc/mhonarc/MHonArc/lib/mhrcfile.pl,v
retrieving revision 2.34
retrieving revision 2.35
diff -C2 -r2.34 -r2.35
*** mhrcfile.pl	4 Feb 2003 23:31:19 -0000	2.34
--- mhrcfile.pl	22 Feb 2003 04:40:11 -0000	2.35
***************
*** 188,191 ****
--- 188,194 ----
  	    last FMTSW;
  	}
+ 	if ($elem eq 'fasttempfiles') {		# Non-random temp files
+ 	    $FastTempFiles = 1; last FMTSW;
+ 	}
  	if ($elem eq 'fieldstore') {		# Fields to store
  	    @ExtraHFields = ()  if $override;
***************
*** 628,631 ****
--- 631,637 ----
  	    $NODOC = 1; last FMTSW;
  	}
+ 	if ($elem eq 'nofasttempfiles') {	# Random temp files
+ 	    $FastTempFiles = 0; last FMTSW;
+ 	}
  	if ($elem eq 'nofolrefs') {		# Don't print explicit fol/refs
  	    $DoFolRefs = 0; last FMTSW;
***************
*** 878,882 ****
  	if ($elem eq 'defcharset') {		# Default charset
  	    $readmail::TextDefCharset = lc get_elem_last_line($handle, $elem);
! 	    $readmail::TextDefCharset = s/\s//g;
  	    $readmail::TextDefCharset = 'us-ascii'
  		if $readmail::TextDefCharset eq '';
--- 884,888 ----
  	if ($elem eq 'defcharset') {		# Default charset
  	    $readmail::TextDefCharset = lc get_elem_last_line($handle, $elem);
! 	    $readmail::TextDefCharset =~ s/\s//g;
  	    $readmail::TextDefCharset = 'us-ascii'
  		if $readmail::TextDefCharset eq '';

---------------------------------------------------------------------
To sign-off this list, send email to majordomo(_at_)mhonarc(_dot_)org with the
message text UNSUBSCRIBE MHONARC-DEV