Applying reformime subsequent on makemime

Vladimir Dronnikov dronnikov at gmail.com
Mon Jul 6 10:04:14 UTC 2009


2009/7/6 Vladimir Dronnikov <dronnikov at gmail.com>:
>>>
>>> trying following example:
>>>
>>> $ makemime file1 file2 file3 >mime.txt
>>> $ reformime -x PREFIX <mime.txt
>>>
>>> reformime exits with read error after creating
>>> a zero length "PREFIXfile3"
>>>
>>> Is the user or the applet wrong ? ;-)
>>
>> Vladimir, can you take a look?
>> --
>
> Sure. Can I have here (better as attachment) that mime.txt?
>

OK. I spotted the problem.

reformime wants input lines to be terminated by \r\n, as in SMTP/POP3
protocols. It makes him trivial to use as a filter for popmaildir.

makemime uses just \n to terminate the lines, as its output is
supposed to be fed to sendmail, which in turn, while talking to SMTP
server, will terminate the lines by \r\n.

In other words, the following IS working:
$ makemime f1 f2 f3 | unix2dos | reformime -xPREFIX

So just a decision is needed how reformime should determine lines. Can
you clarify it, Denys?

Best regards,
--
Vladimir


More information about the busybox mailing list