pop3

Tiny pop3 client designed to be tunneled through ssh
git clone git://jacobedwards.org/pop3
Log | Files | Refs

commit 195dd6d74df4d3963c7f266556ac312b4549bfa0
parent 95482492e08e9a80a7fc351ae98fbd4e12089756
Author: Jacob R. Edwards <jacob@jacobedwards.org>
Date:   Sun, 10 Nov 2024 08:08:33 -0800

Leave errno intact for mbox printf error

This was changed awhile ago but never commited. Makes the problem
clearer if the printf call has an error.

Diffstat:
Mpop3.c | 6+++++-
1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/pop3.c b/pop3.c @@ -477,7 +477,11 @@ mbox(FILE *fp, char *msg, char **unused) return -1; } - if (len != 0 || printf("\n") < 0) + if (len != 0) { + errno = ENOBUFS; + return -1; + } + if (printf("\n") < 0) return -1; return 0; }