Re: mini_sendmail doesn't parse recipient corectly
Lasse Hillerøe Petersen <[email protected]>
| Newsgroups | gmane.os.netbsd.devel.pkgsrc.user,gmane.os.netbsd.help |
|---|---|
| Message-ID | <[email protected]> |
Hi! Your mail got me curious about what mini_sendmail was, and I took a look at it. Jef Poskanzner usually writes great stuff, so I was surprised to see a bug. Especially what looks like an "off-by-one" error. It seems the error is not in the original code, but in patch-aa. I CC this to pkgsrc-users, but you should probably file a PR with send-pr. >Hi, i found error in mini_sendmail from pkgsrc, i didn't test on original d= >istribution, only with pkgsrc patches. >Error is in RCPT TO: command, it shorts recipient email address. It's only = >doing, when recipient is write like this key: "Some Name <[email protected]>= >". If I write only email address: "[email protected]" it works fine. The bug is in mini_sendmail.c, remove or comment out line 600-601: dog:../mini_sendmail-1.3.6 $ diff mini_sendmail.cBAK mini_sendmail.c 600,601c600,601 < if (recipient[len] == '>') < --len; --- > /* THIS IS WRONG if (recipient[len] == '>') > --len; END THIS IS WRONG */ Apparantly, someone must have gotten confused while fixing this code. -Lasse