Eric Thomas <ERIC@FRECP11>
Thu, 7 Jan 88 13:13:00 SET
|
>Maybe, maybe not. Why can't listserv just check to see if all message lines
>are valid listserv commands? If just one line is found that is not a valid
>listserv command, then the whole thing is mail. This would take care of 99%
>of the bogus things that are posted to lists by ignorant (read, uneducated)
>users. (I can hear the objection now... "it'll mean having to scan the
>message body twice." Only seldom. Normally, the command files will go
>directly to listserv, not a list, mail files will usually be detected as such
>on the very first line.)
1. If you have a signature after your command, it is likely to be an invalid
command and will cause the file to be treated as mail.
2. You forget about the '//' control lines, which are valid inside a job file
and are difficult enough to syntax-check.
The only way out would be to execute the mailfile first, stopping as soon as
an invalid line is encountered (which is already the case anyway), and then
treat it as mail if no command was successfully executed. I hope you realize
that this is really dirty programming.
Eric
|
|
|