Paul J Stevens пишет:
I looked at the code for smtp-sink.c.
It does the same as dbmail-lmtp: read one char at a time. Only
difference is that it uses getc(2) rather than read(2).
But it looks like it works with 4k blocks. It's 4096 times faster :)
read(5, "AiAC0AIgA/AD8AIgBABC4AIgBfAC0AOw"..., 4096) = 4096
poll([{fd=5, events=POLLIN, revents=POLLIN}], 1, 0) = 1
poll([{fd=5, events=POLLIN, revents=POLLIN}], 1, 100000) = 1
read(5, "MDEIAAEx\r\nADEAMwA2ABAEMAAwADIAFA"..., 4096) = 4096
poll([{fd=5, events=POLLIN, revents=POLLIN}], 1, 0) = 1
poll([{fd=5, events=POLLIN, revents=POLLIN}], 1, 100000) = 1
read(5, "ICAgICANAAA4NjAwMjExMTAzMjM5CgAA"..., 4096) = 4096
poll([{fd=5, events=POLLIN, revents=POLLIN}], 1, 0) = 1
poll([{fd=5, events=POLLIN, revents=POLLIN}], 1, 100000) = 1