Issue Details (XML | Word | Printable)

Key: JAMES-663
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Critical Critical
Assignee: Norman Maurer
Reporter: Stephan Sann
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
JAMES Server

sendmail.py crashes on line "from_addr = os.environ['USER'] + '@' + socket.getfqdn()"

Created: 16/Oct/06 02:01 PM   Updated: 21/Nov/07 08:31 AM
Return to search
Component/s: None
Affects Version/s: 2.3.0
Fix Version/s: 2.3.1

Time Tracking:
Not Specified

Environment: Debian Linux, Python 2.3.5, "Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)"

Resolution Date: 15/Jan/07 08:15 AM


 Description  « Hide
This line in sendmail.py:

    from_addr = os.environ['USER'] + '@' + socket.getfqdn()

causes my mail-delivery to crash:

<---snip--->

Traceback (most recent call last):
  File "/usr/sbin/sendmail", line 126, in ?
    main(sys.argv)
  File "/usr/sbin/sendmail", line 77, in main
    from_addr = os.environ['USER'] + '@' + socket.getfqdn()
  File "/usr/lib/python2.3/UserDict.py", line 19, in __getitem__
    def __getitem__(self, key): return self.data[key]
KeyError: 'USER'

</---snip--->

I think it's an permission-thing, but didn't went any further.

I just changed it to

    from_addr = "postmaster@localhost"

(since the sender is pased by "-f") and now it works.


 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
No work has yet been logged on this issue.