syd@DSI.COM (Syd Weinstein) (11/25/89)
Fix bug in forget/restore logic, not basing message on user level From: Chris A McCoy <mccoy@ecn.purdue.edu> Change to use newer Configure BSD check to avoid some BSD/Sys V determination problems From: Syd Have the subshell command restore the umask so that user files created within the subshell have the default umask of that user. From: syd via request from Jay Schuster When some space problems occurs, Elm takes the emergency exit. The mailbox can then be restored from the files, that are left on the filesystem. Usually the temporary mailbox and the original mailbox are intact. This behaviour is certainly not very ideal, but at least prevents users from unwanted loss of mail! From: isaak!vogt@uunet.UU.NET (Gerald Vogt) Make lock file read only so /bin/mail will not overwrite it and also your mailbox. It needs to be read accessable due to pid locking. From: syd via Biran Haug <haug@columbia.ncr.com> Various errors in the documentation. From: Jos Vos <jos@idca.tds.philips.nl> Fix: From rn, say "| patch -p -N -d DIR", where DIR is your elm source directory. Outside of rn, say "cd DIR; patch -p -N <thisarticle". If you don't have the patch program, apply the following by hand, or get patch (version 2.0, latest patchlevel). After patching: sh Configure -d make make install If patch indicates that patchlevel is the wrong version, you may need to apply one or more previous patches, or the patch may already have been applied. See the patchlevel.h file to find out what has or has not been applied. In any event, don't continue with the patch. If you are missing previous patches they can be obtained from our: archive server. Syd Weinstein elm@DSI.COM The patches are available from the dsinc archive server Send the following message to archive-server@DSI.COM for a list of available patches: Subject: patch list send index elm Index: hdrs/patchlevel.h Prereq: 13 *** ../elm2.2/hdrs/patchlevel.h Fri Nov 24 20:41:27 1989 --- hdrs/patchlevel.h Mon Oct 23 14:45:27 1989 *************** *** 1 **** ! #define PATCHLEVEL 13 --- 1 ---- ! #define PATCHLEVEL 14 Index: Configure Prereq: 2.41.1.3 *** ../elm2.2/Configure Wed Oct 18 20:54:39 1989 --- Configure Tue Nov 14 16:49:27 1989 *************** *** 8,14 **** # and edit it to reflect your system. Some packages may include samples # of config.h for certain machines, so you might look for one of those.) # ! # $Header: /files/home/users/syd/elm.rel/RCS/Configure,v 2.41.1.3 89/10/06 15:38:49 syd Exp $ # # Yes, you may rip this off to use in other distribution packages. # (Note: this Configure script was generated automatically. Rather than --- 8,14 ---- # and edit it to reflect your system. Some packages may include samples # of config.h for certain machines, so you might look for one of those.) # ! # $Header: /files/home/users/syd/elm.rel/RCS/Configure,v 2.41.1.4 89/11/14 16:49:05 syd Exp $ # # Yes, you may rip this off to use in other distribution packages. # (Note: this Configure script was generated automatically. Rather than *************** *** 597,603 **** echo " " $echo $n "Extracting names from $libc for later perusal...$c" nm $libc 2>/dev/null >libc.tmp ! $sed -n -e 's/^.* [AT] _//p' -e 's/^.* [AT] //p' <libc.tmp >libc.list if $contains '^printf$' libc.list >/dev/null 2>&1; then echo "done" else --- 597,603 ---- echo " " $echo $n "Extracting names from $libc for later perusal...$c" nm $libc 2>/dev/null >libc.tmp ! $sed -n -e 's/^.* [AT] *_//p' -e 's/^.* [AT] //p' <libc.tmp >libc.list if $contains '^printf$' libc.list >/dev/null 2>&1; then echo "done" else *************** *** 635,655 **** : make some quick guesses about what we are up against echo " " $echo $n "Hmm... $c" ! if $contains SIGTSTP /usr/include/signal.h >/dev/null 2>&1 ; then ! echo "Looks kind of like a BSD system, but we'll see..." ! echo exit 0 >bsd ! echo exit 1 >usg echo exit 1 >v7 ! elif $contains SIGTSTP /usr/include/sys/signal.h >/dev/null 2>&1 ; then echo "Looks kind of like a BSD system, but we'll see..." echo exit 0 >bsd echo exit 1 >usg echo exit 1 >v7 - elif $contains '^fcntl$' libc.list >/dev/null 2>&1 ; then - echo "Looks kind of like a USG system, but we'll see..." - echo exit 1 >bsd - echo exit 0 >usg - echo exit 1 >v7 else echo "Looks kind of like a version 7 system, but we'll see..." echo exit 1 >bsd --- 635,651 ---- : make some quick guesses about what we are up against echo " " $echo $n "Hmm... $c" ! cat /usr/include/signal.h /usr/include/sys/signal.h >foo ! if test `echo abc | tr a-z A-Z` = Abc ; then ! echo "Looks kind of like a USG system, but we'll see..." ! echo exit 1 >bsd ! echo exit 0 >usg echo exit 1 >v7 ! elif $contains SIGTSTP foo >/dev/null 2>&1 ; then echo "Looks kind of like a BSD system, but we'll see..." echo exit 0 >bsd echo exit 1 >usg echo exit 1 >v7 else echo "Looks kind of like a version 7 system, but we'll see..." echo exit 1 >bsd *************** *** 656,677 **** echo exit 1 >usg echo exit 0 >v7 fi ! if $contains '^vmssystem$' libc.list >/dev/null 2>&1 ; then cat <<'EOI' There is, however, a strange, musty smell in the air that reminds me of something...hmm...yes...I've got it...there's a VMS nearby, or I'm a Blit. EOI echo "exit 0" >eunice - eunicefix=unixtovms d_eunice="$define" ! : it so happens the Eunice I know will not run shell scripts in Unix format ! else echo " " echo "Congratulations. You aren't running Eunice." - eunicefix=':' d_eunice="$undef" echo "exit 1" >eunice ! fi if test -f /xenix; then echo "Actually, this looks more like a XENIX system..." echo "exit 0" >xenix --- 652,673 ---- echo exit 1 >usg echo exit 0 >v7 fi ! case "$eunicefix" in ! *unixtovms*) cat <<'EOI' There is, however, a strange, musty smell in the air that reminds me of something...hmm...yes...I've got it...there's a VMS nearby, or I'm a Blit. EOI echo "exit 0" >eunice d_eunice="$define" ! ;; ! *) echo " " echo "Congratulations. You aren't running Eunice." d_eunice="$undef" echo "exit 1" >eunice ! ;; ! esac if test -f /xenix; then echo "Actually, this looks more like a XENIX system..." echo "exit 0" >xenix *************** *** 696,701 **** --- 692,698 ---- fi chmod +x bsd usg v7 eunice venix $eunicefix bsd usg v7 eunice venix + rm -rf foo rmlist="$rmlist bsd usg v7 eunice venix xenix" : see if sh knows # comments Index: Patchlist *** ../elm2.2/Patchlist Fri Nov 24 20:41:31 1989 --- Patchlist Fri Nov 24 22:15:34 1989 *************** *** 1,12 **** ! Subject: elm 2.2 Patch #13 ! Date: Mon Oct 23 14:40:29 EDT 1989 (Creation, not message date) Priority: HIGH ! Security patch for default mailboxes to prevent unauthorized access From: Syd ! Change in Filter Error message for missing variable ! From: Andrea Subject: elm 2.2 Patch #13 Date: Mon Oct 23 14:40:29 EDT 1989 (Creation, not message date) --- 1,31 ---- ! Subject: elm 2.2 Patch #14 ! Date: Fri Nov 24 22:14:56 EST 1989 (Creation, not message date) Priority: HIGH ! Fix bug in forget/restore logic, not basing message on user level ! From: Chris A McCoy <mccoy@ecn.purdue.edu> ! ! Change to use newer Configure BSD check to avoid some BSD/Sys V ! determination problems From: Syd ! Have the subshell command restore the umask so that user files created ! within the subshell have the default umask of that user. ! From: syd via request from Jay Schuster ! ! When some space problems occurs, Elm takes the emergency exit. ! The mailbox can then be restored from the files, that are left ! on the filesystem. Usually the temporary mailbox and the original ! mailbox are intact. This behaviour is certainly not very ideal, ! but at least prevents users from unwanted loss of mail! ! From: isaak!vogt@uunet.UU.NET (Gerald Vogt) ! ! Make lock file read only so /bin/mail will not overwrite it and also ! your mailbox. It needs to be read accessable due to pid locking. ! From: syd via Biran Haug <haug@columbia.ncr.com> ! ! Various errors in the documentation. ! From: Jos Vos <jos@idca.tds.philips.nl> Subject: elm 2.2 Patch #13 Date: Mon Oct 23 14:40:29 EDT 1989 (Creation, not message date) Index: doc/Alias.guide Prereq: 2.9 *** ../elm2.2/doc/Alias.guide Mon May 8 21:53:48 1989 --- doc/Alias.guide Fri Nov 24 22:02:04 1989 *************** *** 1,4 **** ! \" @(#)$Id: Alias.guide,v 2.9 89/05/04 14:48:47 syd Exp $ \" \" A guide to the ELM alias system and so on. \" format with: --- 1,4 ---- ! \" @(#)$Id: Alias.guide,v 2.9.1.1 89/11/24 22:01:35 syd Exp $ \" \" A guide to the ELM alias system and so on. \" format with: *************** *** 11,16 **** --- 11,20 ---- \" Syd Weinstein elm@dsinc.UUCP (dsinc!elm) \" \" $Log: Alias.guide,v $ + \" Revision 2.9.1.1 89/11/24 22:01:35 syd + \" Fix documentation errors + \" From: Jos Vos <jos@idca.tds.philips.nl> + \" \" Revision 2.9 89/05/04 14:48:47 syd \" Make pathalias sorting requirement more forceful. Add extra %'s on pathalias \" data lines in examples. *************** *** 542,548 **** } $1 ~ /[Aa]lias | [Gg]roup/ { if ( NF == 3) ! print $2 " : user alias : " $3; else { group = "" for (i = 3; i <= NF; i++) { --- 546,552 ---- } $1 ~ /[Aa]lias | [Gg]roup/ { if ( NF == 3) ! print $2 " = user alias = " $3; else { group = "" for (i = 3; i <= NF; i++) { *************** *** 557,563 **** else group = $i; } ! print $2 " : group alias : " group; } } --- 561,567 ---- else group = $i; } ! print $2 " = group alias = " group; } } Index: doc/Config.guid Prereq: 2.13 *** ../elm2.2/doc/Config.guid Wed Mar 29 16:56:46 1989 --- doc/Config.guid Fri Nov 24 22:02:07 1989 *************** *** 1,4 **** ! \" @(#)$Id: Config.guid,v 2.13 89/03/29 16:56:35 syd Exp $ \" \" A guide to the ELM alias system and so on. \" format with: --- 1,4 ---- ! \" @(#)$Id: Config.guid,v 2.13.1.1 89/11/24 22:02:05 syd Exp $ \" \" A guide to the ELM alias system and so on. \" format with: *************** *** 11,16 **** --- 11,20 ---- \" Syd Weinstein elm@dsinc.UUCP (dsinc!elm) \" \" $Log: Config.guid,v $ + \" Revision 2.13.1.1 89/11/24 22:02:05 syd + \" Fix documentation errors + \" From: Jos Vos <jos@idca.tds.philips.nl> + \" \" Revision 2.13 89/03/29 16:56:35 syd \" Update for 2.2 release \" *************** *** 282,288 **** file. This is used when the user chooses to auto-save the options from within the main program. .lp elmrcfile 1.0i ! The name of the automatic control file (currently \f2.elmrc\f1) .lp old_elmrcfile 1.0i When a new elmrc file is saved, the old one is also saved, being renamed to whatever this identifier is set to. --- 286,292 ---- file. This is used when the user chooses to auto-save the options from within the main program. .lp elmrcfile 1.0i ! The name of the automatic control file (currently \f2.elm/elmrc\f1) .lp old_elmrcfile 1.0i When a new elmrc file is saved, the old one is also saved, being renamed to whatever this identifier is set to. Index: doc/Filter.guid Prereq: 2.8 *** ../elm2.2/doc/Filter.guid Thu Mar 30 16:07:52 1989 --- doc/Filter.guid Fri Nov 24 22:02:11 1989 *************** *** 1,4 **** ! \" @(#)$Id: Filter.guid,v 2.8 89/03/30 16:07:43 syd Exp $ \" \" A guide to the Elm Filter program \" format with: --- 1,4 ---- ! \" @(#)$Id: Filter.guid,v 2.8.1.2 89/11/24 22:02:08 syd Exp $ \" \" A guide to the Elm Filter program \" format with: *************** *** 12,17 **** --- 12,25 ---- \" Syd Weinstein elm@dsinc.UUCP (dsinc!elm) \" \" $Log: Filter.guid,v $ + \" Revision 2.8.1.2 89/11/24 22:02:08 syd + \" Fix documentation errors + \" From: Jos Vos <jos@idca.tds.philips.nl> + \" + \" Revision 2.8.1.1 89/11/24 21:43:09 syd + \" Make use of CW font consistent, change all C to CW + \" From: Syd via Jos Vos + \" \" Revision 2.8 89/03/30 16:07:43 syd \" First tmac.n checkin \" *************** *** 181,186 **** --- 189,195 ---- lf3 lf3 l l. Macro Meaning + .ft CW %d day of the month %D day of the week (0-6) %h hour of the day (0-23) *************** *** 187,193 **** %m month of the year (0-11) %r return address of message %s subject of original message ! %S ``Re: \f2subject of original message\f1'' .ft CW %t current hour and minute in HH:MM format %y year (last two digits) --- 196,202 ---- %m month of the year (0-11) %r return address of message %s subject of original message ! %S ``Re: \f2subject of original message\fP'' .ft CW %t current hour and minute in HH:MM format %y year (last two digits) *************** *** 198,204 **** and blank lines. .sp The file itself needs to reside in your home directory and be ! called \f2.filter-rules\f1. Here's an example:\fC .nf # $HOME/.filter-rules # --- 207,213 ---- and blank lines. .sp The file itself needs to reside in your home directory and be ! called \f2.filter-rules\f1. Here's an example:\f(CW .nf # $HOME/.filter-rules # *************** *** 329,335 **** .fi If you want to have a copy saved to a file. A possible strategy would be to have the errors written to a file and to then have a few lines in ! your \f2.login\f1 script like:\fC .nf .ft CW .in .5i+\w'if 'u --- 338,344 ---- .fi If you want to have a copy saved to a file. A possible strategy would be to have the errors written to a file and to then have a few lines in ! your \f2.login\f1 script like:\f(CW .nf .ft CW .in .5i+\w'if 'u *************** *** 356,362 **** .sp The \f2Filter\f1 program keeps a log of all actions performed, including what rules it matched against, in your home directory in a file ! called \f2.filter_log\f1. You can either directly operate on this file, or, much more recommended, you can one of the two summarize flags to the program and let \f2it\f1 do the work for you! .sp --- 365,371 ---- .sp The \f2Filter\f1 program keeps a log of all actions performed, including what rules it matched against, in your home directory in a file ! called \f2.filterlog\f1. You can either directly operate on this file, or, much more recommended, you can one of the two summarize flags to the program and let \f2it\f1 do the work for you! .sp *************** *** 417,423 **** The preferred way is to have a line in either your \f2crontab\f1 (ask your administrator for help with this) that invokes the \f2filter\f1 program as often as you desire with the \f3-s\f1 flag. For example, I ! have a summary mailed to me every morning at 8:00 am:\fC .nf 0 8 * * * "/usr/local/bin/filter -s | elm -s 'Filter Summary' taylor" .fi --- 426,432 ---- The preferred way is to have a line in either your \f2crontab\f1 (ask your administrator for help with this) that invokes the \f2filter\f1 program as often as you desire with the \f3-s\f1 flag. For example, I ! have a summary mailed to me every morning at 8:00 am:\f(CW .nf 0 8 * * * "/usr/local/bin/filter -s | elm -s 'Filter Summary' taylor" .fi *************** *** 428,434 **** summary is generated you'll need to use the '-c' flag too. Also, if you want to keep a long list of actions performed you can do this by saving it as you display it. A way to do this would be, if you were to ! have the invocation in your \f2.login\f1 script, to use:\fC .nf .in .5i .ft CW --- 437,443 ---- summary is generated you'll need to use the '-c' flag too. Also, if you want to keep a long list of actions performed you can do this by saving it as you display it. A way to do this would be, if you were to ! have the invocation in your \f2.login\f1 script, to use:\f(CW .nf .in .5i .ft CW Index: doc/Form.guide Prereq: 2.9 *** ../elm2.2/doc/Form.guide Wed May 24 21:15:46 1989 --- doc/Form.guide Fri Nov 24 22:02:13 1989 *************** *** 1,4 **** ! \" @(#)$Id: Form.guide,v 2.9 89/05/24 19:13:06 syd Exp $ \" \" A guide to using the Elm Forms mode \" format with: --- 1,4 ---- ! \" @(#)$Id: Form.guide,v 2.9.2.1 89/11/24 22:02:11 syd Exp $ \" \" A guide to using the Elm Forms mode \" format with: *************** *** 12,17 **** --- 12,21 ---- \" (C) Copyright 1988, 1989 Usenet Community Trust \" \" $Log: Form.guide,v $ + \" Revision 2.9.2.1 89/11/24 22:02:11 syd + \" Fix documentation errors + \" From: Jos Vos <jos@idca.tds.philips.nl> + \" \" Revision 2.9 89/05/24 19:13:06 syd \" make commands look transparent to mailer to avoid mis interpretation \" From: Phil Hochstetler *************** *** 255,261 **** .hu Composing and Sending a Form The first step to enable sending forms is to change the setting of ! the variable \f2forms\f1 in your \f2.elmrc\f1 file to ``ON''. E.g.: .nf .ti .5i forms = ON --- 259,265 ---- .hu Composing and Sending a Form The first step to enable sending forms is to change the setting of ! the variable \f2forms\f1 in your \f2.elm/elmrc\f1 file to ``ON''. E.g.: .nf .ti .5i forms = ON Index: doc/Ref.guide Prereq: 2.29 *** ../elm2.2/doc/Ref.guide Mon Jun 12 10:21:43 1989 --- doc/Ref.guide Fri Nov 24 22:02:22 1989 *************** *** 1,4 **** ! \" @(#)$Id: Ref.guide,v 2.29 89/05/31 14:47:10 syd Exp $ \" \" Reference guide to the Elm mail system. \" format with --- 1,4 ---- ! \" @(#)$Id: Ref.guide,v 2.29.1.3 89/11/24 22:02:14 syd Exp $ \" \" Reference guide to the Elm mail system. \" format with *************** *** 12,17 **** --- 12,29 ---- \" (C) Copyright 1988, 1989 Usenet Community Trust \" \" $Log: Ref.guide,v $ + \" Revision 2.29.1.3 89/11/24 22:02:14 syd + \" Fix documentation errors + \" From: Jos Vos <jos@idca.tds.philips.nl> + \" + \" Revision 2.29.1.2 89/11/24 21:43:34 syd + \" Make use of CW font consistent, change all C to CW + \" From: Syd via Jos Vos + \" + \" Revision 2.29.1.1 89/11/24 21:33:51 syd + \" Fix location of sig file + \" From: Esmond Pitt + \" \" Revision 2.29 89/05/31 14:47:10 syd \" Minor spelling changes \" From: Dave Yearke *************** *** 247,252 **** --- 259,265 ---- .ft CW print = print -formfeed print = pr %s | lpr + .br .ft 1 .fi (The default is set by the person who configured \f2elm\f1 for your system.) *************** *** 284,291 **** mail and \f2remote\f1 mail (remote being via other hosts), you can alternatively define two variables, \f2localsignature\f1 and \f2remotesignature\f1, to have the same functionality. ! (The default is "localsignature" and "remotesignature" in the \f2.elm\f1 ! directory in your home directory.) .lp sortby* 1.0i You can have your folder sorted by any of the following ways: --- 297,304 ---- mail and \f2remote\f1 mail (remote being via other hosts), you can alternatively define two variables, \f2localsignature\f1 and \f2remotesignature\f1, to have the same functionality. ! (The default is "localsignature" and "remotesignature" in ! your home directory.) .lp sortby* 1.0i You can have your folder sorted by any of the following ways: *************** *** 1578,1587 **** database, with a file containing lines with the format: .nf .ti .5i ! \f2hostname\f1 \f2address\fC!%s\f1 or .ti .5i ! \f2hostname\f1 \fC%s@\f2hostname\f1 .fi The actual details of the file are located in \f2The Alias System Users Guide\f1. --- 1591,1600 ---- database, with a file containing lines with the format: .nf .ti .5i ! \f2hostname\f1 \f2address\f(CW!%s\f1 or .ti .5i ! \f2hostname\f1 \f(CW%s@\f2hostname\f1 .fi The actual details of the file are located in \f2The Alias System Users Guide\f1. Index: doc/Users.guide Prereq: 2.19 *** ../elm2.2/doc/Users.guide Mon Jun 12 10:21:44 1989 --- doc/Users.guide Fri Nov 24 22:02:28 1989 *************** *** 1,4 **** ! \" @(#)$Id: Users.guide,v 2.19 89/05/31 14:48:05 syd Exp $ \" \" Users guide to the ELM mail system. \" format with: --- 1,4 ---- ! \" @(#)$Id: Users.guide,v 2.19.1.1 89/11/24 22:02:24 syd Exp $ \" \" Users guide to the ELM mail system. \" format with: *************** *** 12,17 **** --- 12,21 ---- \" (C) Copyright 1988, 1989 Usenet Community Trust \" \" $Log: Users.guide,v $ + \" Revision 2.19.1.1 89/11/24 22:02:24 syd + \" Fix documentation errors + \" From: Jos Vos <jos@idca.tds.philips.nl> + \" \" Revision 2.19 89/05/31 14:48:05 syd \" Minor spelling change \" From: Dave Yearke *************** *** 479,485 **** original message included, whereas a bounced message is still from the original sender. .ef ! .lp \h'18p'g" Group reply \(em reply to everyone who received the current message. .lp \h'18p'h 90p Display message with headers. --- 483,489 ---- original message included, whereas a bounced message is still from the original sender. .ef ! .lp \h'18p'g 90p Group reply \(em reply to everyone who received the current message. .lp \h'18p'h 90p Display message with headers. *************** *** 765,771 **** .fi The mailer will then prompt for Subject, Copies, and then drop ! you in your editor (defined in the \f2.elmrc\f1 file) to compose the message. When composition is complete, the program verifies transmission then terminates. --- 769,775 ---- .fi The mailer will then prompt for Subject, Copies, and then drop ! you in your editor (defined in the \f2.elm/elmrc\f1 file) to compose the message. When composition is complete, the program verifies transmission then terminates. *************** *** 941,947 **** The most basic of mailers, this one was simply the example of how \f2not\f1 to force the user to interact with a program. ! .lp \h'4p'\f2Berkeley Mail\f1 1.0i A surprisingly sophisticated mailer, especially the version with 4.3 BSD, \f2Berkeley Mail\f1 still suffers from the tendency to force the user to know too much about the system, and also lacks a friendly, non-cryptic --- 945,951 ---- The most basic of mailers, this one was simply the example of how \f2not\f1 to force the user to interact with a program. ! .lp "\h'4p'\f2Berkeley Mail\f1" 1.0i A surprisingly sophisticated mailer, especially the version with 4.3 BSD, \f2Berkeley Mail\f1 still suffers from the tendency to force the user to know too much about the system, and also lacks a friendly, non-cryptic Index: doc/answer.1 *** ../elm2.2/doc/answer.1 Wed Apr 19 11:55:40 1989 --- doc/answer.1 Fri Nov 24 22:02:30 1989 *************** *** 49,57 **** .br newalias(1L), checkalias(1L), mail(1), mailx(1), from(1L), printmail(1L) .SH FILES ! $home/.elm/aliases.hash individual alias hash table .br ! $home/.elm/aliases.data individual alias data table .br /tmp/snd.$$ edit buffer for outgoing mail .SH BUG REPORTS TO --- 49,59 ---- .br newalias(1L), checkalias(1L), mail(1), mailx(1), from(1L), printmail(1L) .SH FILES ! $HOME/.elm/aliases.text individual alias source .br ! $HOME/.elm/aliases.hash individual alias hash table ! .br ! $HOME/.elm/aliases.data individual alias data table .br /tmp/snd.$$ edit buffer for outgoing mail .SH BUG REPORTS TO Index: doc/elm.1 *** ../elm2.2/doc/elm.1 Fri Mar 31 09:41:08 1989 --- doc/elm.1 Fri Nov 24 22:02:34 1989 *************** *** 73,79 **** Checkalias - expand the following aliases and return. .TP .B " -d \fIlevel\fR " ! Debug - set specified debug level - Output to "$HOME/Elm:debug.info" .TP .B " -f \fIalternative-folder\fR " Folder - read folder (specified) rather than the incoming mailbox. --- 73,79 ---- Checkalias - expand the following aliases and return. .TP .B " -d \fIlevel\fR " ! Debug - set specified debug level - Output to "$HOME/ELM:debug.info" .TP .B " -f \fIalternative-folder\fR " Folder - read folder (specified) rather than the incoming mailbox. *************** *** 115,125 **** .br newalias(1L), checkalias(1L), mail(1), mailx(1), frm(1L), printmail(1L) .SH FILES ! /usr/local/bin/elm-help.main help file .br ! /usr/local/lib/.alias_hash system alias hash table .br ! /usr/local/lib/.alias_data system alias data table .br $HOME/.elm/aliases.hash user alias hash table .br --- 115,129 ---- .br newalias(1L), checkalias(1L), mail(1), mailx(1), frm(1L), printmail(1L) .SH FILES ! /usr/local/lib/elm-help.* help files .br ! /usr/local/lib/aliases.text system alias source .br ! /usr/local/lib/aliases.hash system alias hash table ! .br ! /usr/local/lib/aliases.data system alias data table ! .br ! $HOME/.elm/aliases.hash user alias source .br $HOME/.elm/aliases.hash user alias hash table .br Index: doc/filter.1 *** ../elm2.2/doc/filter.1 Wed Oct 18 20:54:41 1989 --- doc/filter.1 Fri Nov 24 22:02:36 1989 *************** *** 94,100 **** .TP .B "-v" Verbose. Give output on standard out for each message filtered. Useful ! to have redirected to ``/dev/console'' and such. (see \fB-a\fR too). .SH AUTHOR Dave Taylor, Hewlett-Packard Laboratories. .SH FILES --- 94,100 ---- .TP .B "-v" Verbose. Give output on standard out for each message filtered. Useful ! to have redirected to ``/dev/console'' and such. (see \fB-o\fR too). .SH AUTHOR Dave Taylor, Hewlett-Packard Laboratories. .SH FILES Index: doc/newalias.1 *** ../elm2.2/doc/newalias.1 Sun Feb 26 16:38:11 1989 --- doc/newalias.1 Fri Nov 24 22:02:38 1989 *************** *** 53,63 **** .br $HOME/.elm/aliases.data alias data file for user .br ! /usr/mail/.alias_text alias source for system .br ! /usr/mail/.alias_hash alias hash table for system .br ! /usr/mail/.alias_data alias data file for system .SH AUTHOR Dave Taylor, Hewlett-Packard Laboratories. .SH SEE\ ALSO --- 53,63 ---- .br $HOME/.elm/aliases.data alias data file for user .br ! /usr/local/lib/aliases.text alias source for system .br ! /usr/local/lib/aliases.hash alias hash table for system .br ! /usr/local/lib/aliases.data alias data file for system .SH AUTHOR Dave Taylor, Hewlett-Packard Laboratories. .SH SEE\ ALSO Index: doc/readmsg.1 *** ../elm2.2/doc/readmsg.1 Sun Feb 26 16:38:18 1989 --- doc/readmsg.1 Fri Nov 24 22:02:42 1989 *************** *** 122,128 **** .SH FILES /usr/mail/<username> The incoming mail .br ! $home/.readmsg The temp file from \fIelm\fR .SH AUTHOR Dave Taylor, Hewlett-Packard Laboratories .SH SEE\ ALSO --- 122,128 ---- .SH FILES /usr/mail/<username> The incoming mail .br ! $HOME/.readmsg The temp file from \fIelm\fR .SH AUTHOR Dave Taylor, Hewlett-Packard Laboratories .SH SEE\ ALSO Index: filter/lock.c Prereq: 2.4 *** ../elm2.2/filter/lock.c Thu Mar 30 10:34:08 1989 --- filter/lock.c Fri Nov 24 21:29:23 1989 *************** *** 1,8 **** ! static char rcsid[] ="@(#)$Id: lock.c,v 2.4 89/03/25 21:45:14 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.4 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] ="@(#)$Id: lock.c,v 2.4.1.1 89/11/24 21:29:21 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.4.1.1 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,24 ---- * ******************************************************************************* * $Log: lock.c,v $ + * Revision 2.4.1.1 89/11/24 21:29:21 syd + * Make lock file read only so /bin/mail will not overwrite it and also + * your mailbox. It needs to be read accessable due to pid locking. + * From: syd via Biran Haug <haug@columbia.ncr.com> + * * Revision 2.4 89/03/25 21:45:14 syd * Initial 2.2 Release checkin * *************** *** 47,53 **** sprintf(lockfile, "%s%s.lock", mailhome, username); ! while ((ret = open(lockfile, O_WRONLY | O_CREAT | O_EXCL, 0777)) < 0 && attempts++ < 10) { sleep(3); /* wait three seconds each pass, okay?? */ } --- 52,58 ---- sprintf(lockfile, "%s%s.lock", mailhome, username); ! while ((ret = open(lockfile, O_WRONLY | O_CREAT | O_EXCL, 0444)) < 0 && attempts++ < 10) { sleep(3); /* wait three seconds each pass, okay?? */ } Index: hdrs/elm.h Prereq: 2.22.1.1 *** ../elm2.2/hdrs/elm.h Fri Nov 24 20:41:28 1989 --- hdrs/elm.h Fri Nov 24 20:51:02 1989 *************** *** 1,8 **** ! /* $Id: elm.h,v 2.22.1.1 89/10/23 14:18:18 syd Exp $ */ /******************************************************************************* ! * The Elm Mail System - $Revision: 2.22.1.1 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! /* $Id: elm.h,v 2.22.1.2 89/11/24 20:51:00 syd Exp $ */ /******************************************************************************* ! * The Elm Mail System - $Revision: 2.22.1.2 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,24 ---- * ******************************************************************************* * $Log: elm.h,v $ + * Revision 2.22.1.2 89/11/24 20:51:00 syd + * Have the subshell command restore the umask so that user files created + * within the subshell have the default umask of that user. + * From: syd via request from Jay Schuster + * * Revision 2.22.1.1 89/10/23 14:18:18 syd * Add errno for can_access checking * From: Syd *************** *** 58,63 **** --- 63,69 ---- int last_header_page = -1; /* last header page */ int message_count = 0; /* max message number */ int headers_per_page; /* number of headers/page */ + int original_umask = 0; /* original umask, for restore before subshell */ int sendmail_verbose = 0; /* Extended mail debugging */ char cur_folder[SLEN] = {0}; /* name of current folder */ char cur_tempfolder[SLEN] = {0}; /* name of temp folder open for a mailbox */ Index: hdrs/headers.h Prereq: 2.19 *** ../elm2.2/hdrs/headers.h Fri Apr 28 16:05:27 1989 --- hdrs/headers.h Fri Nov 24 20:51:04 1989 *************** *** 1,8 **** ! /* $Id: headers.h,v 2.19 89/04/28 14:48:18 syd Exp $ */ /******************************************************************************* ! * The Elm Mail System - $Revision: 2.19 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! /* $Id: headers.h,v 2.19.1.1 89/11/24 20:51:02 syd Exp $ */ /******************************************************************************* ! * The Elm Mail System - $Revision: 2.19.1.1 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,24 ---- * ******************************************************************************* * $Log: headers.h,v $ + * Revision 2.19.1.1 89/11/24 20:51:02 syd + * Have the subshell command restore the umask so that user files created + * within the subshell have the default umask of that user. + * From: syd via request from Jay Schuster + * * Revision 2.19 89/04/28 14:48:18 syd * This reinstates elm 2.1 functionality of saving a copy of an outbound * message by name only if the folder preexists, while keeping the new *************** *** 48,53 **** --- 53,59 ---- extern int last_header_page; /* last header page */ extern int message_count; /* max message number */ extern int headers_per_page; /* number of headers/page */ + extern int original_umask; /* original umask, for restore before subshell */ extern int sendmail_verbose; /* Allow extended debugging on sendmail */ extern char cur_folder[SLEN]; /* name of current folder */ extern char cur_tempfolder[SLEN]; /* name of temp folder open for a mailbox */ Index: src/alias.c Prereq: 2.14 *** ../elm2.2/src/alias.c Thu Mar 30 10:34:56 1989 --- src/alias.c Fri Nov 24 21:02:59 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: alias.c,v 2.14 89/03/30 10:25:28 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.14 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: alias.c,v 2.14.1.1 89/11/24 21:02:57 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.14.1.1 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,27 ---- * ******************************************************************************* * $Log: alias.c,v $ + * Revision 2.14.1.1 89/11/24 21:02:57 syd + * When some space problems occurs, Elm takes the emergency exit. + * The mailbox can then be restored from the files, that are left + * on the filesystem. Usually the temporary mailbox and the original + * mailbox are intact. This behaviour is certainly not very ideal, + * but at least prevents users from unwanted loss of mail! + * From: isaak!vogt@uunet.UU.NET (Gerald Vogt) + * * Revision 2.14 89/03/30 10:25:28 syd * Check variable value for being in valid range before using to prevent * segmentation violation. *************** *** 293,299 **** return(1); } ! fprintf(file,"%s = %s = %s\n", name, comment, address); fclose(file); restore_file_stats(fname); --- 301,317 ---- return(1); } ! if (fprintf(file,"%s = %s = %s\n", name, comment, address) == EOF) { ! dprint(2, (debugfile, ! "Failure attempting to write alias to file within %s", ! fname, "add_to_alias_text")); ! dprint(2, (debugfile, "** %s - %s **\n", error_name(errno), ! error_description(errno))); ! error1("Couldn't write alias to file %s!", fname); ! fclose(file); ! return(1); ! } ! fclose(file); restore_file_stats(fname); *************** *** 344,350 **** { if (strncmp(name_with_equals, line_in_file, strlen(name_with_equals)) != 0) ! fprintf(tmpfile,"%s", line_in_file); } fclose(file); fclose(tmpfile); --- 362,379 ---- { if (strncmp(name_with_equals, line_in_file, strlen(name_with_equals)) != 0) ! if (fprintf(tmpfile,"%s", line_in_file) == EOF) { ! dprint(2, (debugfile, ! "Failure attempting to write to temp file %s within %s", ! tmpfname, "delete_from_alias_text")); ! dprint(2, (debugfile, "** %s - %s **\n", error_name(errno), ! error_description(errno))); ! error1("Couldn't write to tempfile %s!", tmpfname); ! fclose(file); ! fclose(tmpfile); ! unlink(tmpfname); ! return(1); ! } } fclose(file); fclose(tmpfile); Index: src/elm.c Prereq: 2.35.1.1 *** ../elm2.2/src/elm.c Fri Nov 24 20:41:29 1989 --- src/elm.c Wed Oct 25 12:05:00 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: elm.c,v 2.35.1.1 89/10/23 14:22:35 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.35.1.1 $ $State: Exp $ * * This file and all associated files and documentation: * Copyright (c) 1986, 1987 Dave Taylor --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: elm.c,v 2.35.1.2 89/10/25 12:04:52 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.35.1.2 $ $State: Exp $ * * This file and all associated files and documentation: * Copyright (c) 1986, 1987 Dave Taylor *************** *** 15,20 **** --- 15,24 ---- * ******************************************************************************* * $Log: elm.c,v $ + * Revision 2.35.1.2 89/10/25 12:04:52 syd + * Add missing errno extern + * From: Syd + * * Revision 2.35.1.1 89/10/23 14:22:35 syd * Security fix for default mail box * From: Syd *************** *** 62,67 **** --- 66,72 ---- last_in_folder; /** for when we receive new mail too... **/ long num; /** another variable for fun.. **/ extern char version_buff[]; + extern int errno; req_mfile = parse_arguments(argc, argv, to_whom); Index: src/file_util.c Prereq: 2.8 *** ../elm2.2/src/file_util.c Thu Mar 30 10:35:54 1989 --- src/file_util.c Fri Nov 24 21:03:01 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: file_util.c,v 2.8 89/03/25 21:46:19 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.8 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: file_util.c,v 2.8.1.1 89/11/24 21:03:00 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.8.1.1 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,27 ---- * ******************************************************************************* * $Log: file_util.c,v $ + * Revision 2.8.1.1 89/11/24 21:03:00 syd + * When some space problems occurs, Elm takes the emergency exit. + * The mailbox can then be restored from the files, that are left + * on the filesystem. Usually the temporary mailbox and the original + * mailbox are intact. This behaviour is certainly not very ideal, + * but at least prevents users from unwanted loss of mail! + * From: isaak!vogt@uunet.UU.NET (Gerald Vogt) + * * Revision 2.8 89/03/25 21:46:19 syd * Initial 2.2 Release checkin * *************** *** 211,218 **** } while (fgets(buffer, VERY_LONG_STRING, from_file) != NULL) ! fputs(buffer, to_file); ! fclose(from_file); fclose(to_file); chown( to, userid, groupid); --- 219,229 ---- } while (fgets(buffer, VERY_LONG_STRING, from_file) != NULL) ! if (fputs(buffer, to_file) == EOF) { ! Write_to_screen("\n\rWrite failed to tempfile in copy\n\r", 0); ! perror(to); ! emergency_exit(); ! } fclose(from_file); fclose(to_file); chown( to, userid, groupid); *************** *** 263,269 **** } while (fgets(buffer, VERY_LONG_STRING, from_file) != NULL) ! fputs(buffer, to_file); fclose(from_file); fclose(to_file); --- 274,284 ---- } while (fgets(buffer, VERY_LONG_STRING, from_file) != NULL) ! if (fputs(buffer, to_file) == EOF) { ! Write_to_screen("\n\rWrite failed to tempfile in copy\n\r", 0); ! perror(to); ! emergency_exit(); ! } fclose(from_file); fclose(to_file); *************** *** 291,297 **** } while (fgets(buffer, VERY_LONG_STRING, my_fd) != NULL) ! fputs(buffer, fd); fclose(my_fd); --- 306,316 ---- } while (fgets(buffer, VERY_LONG_STRING, my_fd) != NULL) ! if (fputs(buffer, fd) == EOF) { ! Write_to_screen("\n\rWrite failed to tempfile in copy\n\r", 0); ! perror(filename); ! emergency_exit(); ! } fclose(my_fd); Index: src/fileio.c Prereq: 2.17 *** ../elm2.2/src/fileio.c Wed May 24 21:15:51 1989 --- src/fileio.c Fri Nov 24 21:03:03 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: fileio.c,v 2.17 89/05/24 19:32:32 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.17 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: fileio.c,v 2.17.1.1 89/11/24 21:03:02 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.17.1.1 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,27 ---- * ******************************************************************************* * $Log: fileio.c,v $ + * Revision 2.17.1.1 89/11/24 21:03:02 syd + * When some space problems occurs, Elm takes the emergency exit. + * The mailbox can then be restored from the files, that are left + * on the filesystem. Usually the temporary mailbox and the original + * mailbox are intact. This behaviour is certainly not very ideal, + * but at least prevents users from unwanted loss of mail! + * From: isaak!vogt@uunet.UU.NET (Gerald Vogt) + * * Revision 2.17 89/05/24 19:32:32 syd * Updateing the status line for non forwarded messages was doubling * the status tag. *************** *** 173,179 **** if (!forwarding) { if(! first_word(buffer, "Status:")) { ! fprintf(dest_file, "%s%s", prefix, buffer); continue; } else if (update_status) { --- 181,190 ---- if (!forwarding) { if(! first_word(buffer, "Status:")) { ! if (fprintf(dest_file, "%s%s", prefix, buffer) == EOF) { ! Write_to_screen("\n\rWrite in copy_message failed\n\r", 0); ! emergency_exit(); ! } continue; } else if (update_status) { *************** *** 180,186 **** ignoring = TRUE; continue; /* we will output a new Status: line later. */ } else { ! fprintf(dest_file, "%s%s\n", prefix, buffer); continue; } } --- 191,200 ---- ignoring = TRUE; continue; /* we will output a new Status: line later. */ } else { ! if (fprintf(dest_file, "%s%s", prefix, buffer) == EOF) { ! Write_to_screen("\n\rWrite in copy_message failed\n\r", 0); ! emergency_exit(); ! } continue; } } Index: src/init.c Prereq: 2.30.1.2 *** ../elm2.2/src/init.c Fri Nov 24 20:41:30 1989 --- src/init.c Fri Nov 24 20:50:56 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: init.c,v 2.30.1.2 89/10/23 14:22:39 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.30.1.2 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: init.c,v 2.30.1.3 89/11/24 20:50:10 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.30.1.3 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,24 ---- * ******************************************************************************* * $Log: init.c,v $ + * Revision 2.30.1.3 89/11/24 20:50:10 syd + * Have the subshell command restore the umask so that user files created + * within the subshell have the default umask of that user. + * From: syd via request from Jay Schuster + * * Revision 2.30.1.2 89/10/23 14:22:39 syd * Security fix for default mail box * From: Syd *************** *** 136,142 **** userid = getuid(); groupid = getgid(); ! (void)umask(077); /* make all newly created files private */ /* Get username (logname), home (login directory), and full_username * (part of GCOS) field from the password entry for this user id. --- 141,147 ---- userid = getuid(); groupid = getgid(); ! original_umask = umask(077); /* make all newly created files private */ /* Get username (logname), home (login directory), and full_username * (part of GCOS) field from the password entry for this user id. Index: src/leavembox.c Prereq: 2.27.1.2 *** ../elm2.2/src/leavembox.c Wed Oct 18 20:54:42 1989 --- src/leavembox.c Fri Nov 24 21:29:19 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: leavembox.c,v 2.27.1.2 89/10/18 20:16:08 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.27.1.2 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: leavembox.c,v 2.27.1.3 89/11/24 21:28:07 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.27.1.3 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,24 ---- * ******************************************************************************* * $Log: leavembox.c,v $ + * Revision 2.27.1.3 89/11/24 21:28:07 syd + * Make lock file read only so /bin/mail will not overwrite it and also + * your mailbox. It needs to be read accessable due to pid locking. + * From: syd via Biran Haug <haug@columbia.ncr.com> + * * Revision 2.27.1.2 89/10/18 20:16:08 syd * fix typo * From: Syd *************** *** 646,652 **** do { errno = 0; ! if((create_fd=open(lock_name,O_WRONLY | O_CREAT | O_EXCL,0777)) != -1) break; else { if(errno != EEXIST) { --- 651,657 ---- do { errno = 0; ! if((create_fd=open(lock_name,O_WRONLY | O_CREAT | O_EXCL,0444)) != -1) break; else { if(errno != EEXIST) { *************** *** 712,718 **** } /* we've removed the bad lock, let's try to assert lock once more */ ! if((create_fd=open(lock_name,O_WRONLY | O_CREAT | O_EXCL,0777)) == -1){ /* still can't lock it - just give up */ dprint(1, (debugfile, --- 717,723 ---- } /* we've removed the bad lock, let's try to assert lock once more */ ! if((create_fd=open(lock_name,O_WRONLY | O_CREAT | O_EXCL,0444)) == -1){ /* still can't lock it - just give up */ dprint(1, (debugfile, Index: src/mailmsg2.c Prereq: 2.35 *** ../elm2.2/src/mailmsg2.c Mon Jun 19 17:16:55 1989 --- src/mailmsg2.c Fri Nov 24 21:03:09 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: mailmsg2.c,v 2.35 89/06/19 16:53:10 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.35 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: mailmsg2.c,v 2.35.1.2 89/11/24 21:03:04 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.35.1.2 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,31 ---- * ******************************************************************************* * $Log: mailmsg2.c,v $ + * Revision 2.35.1.2 89/11/24 21:03:04 syd + * When some space problems occurs, Elm takes the emergency exit. + * The mailbox can then be restored from the files, that are left + * on the filesystem. Usually the temporary mailbox and the original + * mailbox are intact. This behaviour is certainly not very ideal, + * but at least prevents users from unwanted loss of mail! + * From: isaak!vogt@uunet.UU.NET (Gerald Vogt) + * + * Revision 2.35.1.1 89/11/24 20:28:27 syd + * Fix bug in forget/restore logic, not basing message on user level + * From: Chris A McCoy <mccoy@ecn.purdue.edu> + * * Revision 2.35 89/06/19 16:53:10 syd * A recent fix for forms problems wrongly treated a filled in form as a * yet-to-be-filled form, causing problems when the user wanted to reply to it. *************** *** 534,541 **** dead_letter); } ! } else set_error( ! "Message kept. Can be restored at next f)orward, m)ail or r)eply."); break; case '\n' : --- 546,553 ---- dead_letter); } ! } else if (user_level != 0) ! set_error("Message kept. Can be restored at next f)orward, m)ail or r)eply."); break; case '\n' : *************** *** 772,778 **** */ fputs(". \n", dest); else ! fputs(buffer, dest); } if (copy) fputs("\n", dest); /* ensure a blank line at the end */ } --- 784,793 ---- */ fputs(". \n", dest); else ! if (fputs(buffer, dest) == EOF) { ! Write_to_screen("\n\rWrite failed in copy_message_across\n\r", 0); ! emergency_exit(); ! } } if (copy) fputs("\n", dest); /* ensure a blank line at the end */ } Index: src/newmbox.c Prereq: 2.38 *** ../elm2.2/src/newmbox.c Wed May 24 21:15:53 1989 --- src/newmbox.c Fri Nov 24 21:03:12 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: newmbox.c,v 2.38 89/05/24 19:27:08 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.38 $ $State: Exp $ * * Copyright (c) 1988, USENET Community Trust * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: newmbox.c,v 2.38.1.1 89/11/24 21:03:10 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.38.1.1 $ $State: Exp $ * * Copyright (c) 1988, USENET Community Trust * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,27 ---- * ******************************************************************************* * $Log: newmbox.c,v $ + * Revision 2.38.1.1 89/11/24 21:03:10 syd + * When some space problems occurs, Elm takes the emergency exit. + * The mailbox can then be restored from the files, that are left + * on the filesystem. Usually the temporary mailbox and the original + * mailbox are intact. This behaviour is certainly not very ideal, + * but at least prevents users from unwanted loss of mail! + * From: isaak!vogt@uunet.UU.NET (Gerald Vogt) + * * Revision 2.38 89/05/24 19:27:08 syd * Fix garbage headers on reply by setting up no.id header * From: Dave Taylor *************** *** 336,342 **** if (fgets(buffer, LONG_STRING, mailfile) == NULL) break; ! if (copyit) fputs(buffer, temp); line_bytes = (long) strlen(buffer); /* Fix below to increment line count ONLY if we got a full line. --- 344,360 ---- if (fgets(buffer, LONG_STRING, mailfile) == NULL) break; ! if (copyit) ! if (fputs(buffer, temp) == EOF) { ! err = errno; ! Write_to_screen("\n\rWrite to tempfile %s failed!!\n\r", 1, ! cur_tempfolder); ! Write_to_screen("** %s - %s. **\n\r", 2, ! error_name(err), error_description(err)); ! dprint(1, (debugfile, "Can't write to tempfile %s!!\n", ! cur_tempfolder)); ! emergency_exit(); ! } line_bytes = (long) strlen(buffer); /* Fix below to increment line count ONLY if we got a full line. Index: src/syscall.c Prereq: 2.15 *** ../elm2.2/src/syscall.c Wed Apr 19 11:55:45 1989 --- src/syscall.c Fri Nov 24 20:50:59 1989 *************** *** 1,8 **** ! static char rcsid[] = "@(#)$Id: syscall.c,v 2.15 89/04/19 10:56:15 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.15 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust --- 1,8 ---- ! static char rcsid[] = "@(#)$Id: syscall.c,v 2.15.1.1 89/11/24 20:50:56 syd Exp $"; /******************************************************************************* ! * The Elm Mail System - $Revision: 2.15.1.1 $ $State: Exp $ * * Copyright (c) 1986, 1987 Dave Taylor * Copyright (c) 1988, 1989 USENET Community Trust *************** *** 14,19 **** --- 14,24 ---- * ******************************************************************************* * $Log: syscall.c,v $ + * Revision 2.15.1.1 89/11/24 20:50:56 syd + * Have the subshell command restore the umask so that user files created + * within the subshell have the default umask of that user. + * From: syd via request from Jay Schuster + * * Revision 2.15 89/04/19 10:56:15 syd * Better attempt at stop signals * *************** *** 64,70 **** --- 69,77 ---- Raw(OFF); if (cursor_control) transmit_functions(OFF); + umask(original_umask); /* restore original umask so users new files are ok */ ret = system_call(command, USER_SHELL, TRUE); + umask(077); /* now put it back to private for mail files */ PutLine0(LINES, 0, "\n\nPress any key to return to ELM."); -- ===================================================================== Sydney S. Weinstein, CDP, CCP Elm Coordinator Datacomp Systems, Inc. Voice: (215) 947-9900 syd@DSI.COM or {bpa,vu-vlsi}!dsinc!syd FAX: (215) 938-0235