Menu

#1261 Traceback fingers unrelated catch output

open
smtp (24)
5
2011-05-26
2011-05-26
No

Hi,

We had a problem today where we were getting a traceback from tcllib's smtp package while trying to queue a message. The traceback pointed to "key message-id not in header", but this wasn't the problem. The real problem was "451: 4.3.0 Error: queue file write error" because /var was out of space.

Tracing stuff, we found this call, the last line of ::smtp::sendmessage:

return -code 1 -errorinfo {key message-id not in header\n while e...} -errorcode NONE {451: 4.3.0 Error: queue file write error}

The errorinfo is incorrect -- it is from a catch of an innocent error 281 lines into the sendmessage proc, where it says...

if {([lsearch -exact $lowerL ${message-idL}] < 0) \ && ([catch { ::mime::getheader $part ${message-idL} }])} {

This made it much harder to troubleshoot the actual error.

Please fix the smtp package to finger the correct error -- I'm not sure where the bug is but whatever generated the error "451: 4.3.0 Error: queue file write error" did not get the errorinfo set properly. I hope this is enough info.

Discussion