Hello Jan,

Jan Chaloupka <[email protected]> wrote:
 |On 08/01/2014 12:10 PM, Steffen Nurpmeso wrote:
 |> Jan Chaloupka <[email protected]> wrote:
 |>|If email configuration file (/etc/mail.rc) contains line with:
 |>|set from=
 |>|or
 |>|set from= address,
 |>|mailx segfaults.
 |>
 |> Thanks for reporting this.
 |> S-nail could also be crashed (in fact i've also added assert(3)s
 |> that test *from*, but which doesn't really make sense either).
 |> I've release S-nail v14.7.5 because of this.
 |
 |Hello, Steffen,
 |
 |thank you for reply. Have you noticed other issues connected with empty 
 |values?
 |Besides from=? If there are more such issues, more checks can be added. Or
 |more sophisticated way of checking implemented.

No, i haven't, even once i've converted all the value handling
from string to enumeration lookups, including addition of a hard
difference in between binary and valued options (instead of
checking a pointer return value accordingly).  (To say the truth
i was positively surprised, even if the codebase is so old and has
seen so many eyes.)

No, *from* is treated terribly special, just compare the functions
myorigin() and myaddrs().  And note this is evaluated many
times...  For S-nail in particular this lazy over-and-over-again
evaluation will be replaced with with an initial setup, plus
a possible update shall we be interactive and have seen
a collect() in between.  I think this is crucial to get all that
straight, including the possibility to give user really useful
feedback, before anything happens, and maybe giving her an option
how to continue (save draft, enter a *from* or whatever).

E.g., the patch you've sent for Heirloom mailx will print the
warning message from within a forked subprocess, and even may do
so for each and every recipient which will be addressed over SMTP,
unless i'm mistaken...  Better use sendout.c:start_mta() before
the fork or even better further up the call chain!

--steffen

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
S-nail-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/s-nail-users

Reply via email to