summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSunil Nimmagadda <sunil@nimmagadda.net>2014-04-02 13:13:34 +0500
committerSunil Nimmagadda <sunil@nimmagadda.net>2014-04-02 13:13:34 +0500
commited034f8989e711a99be36d0f148d8e65ad5d0c88 (patch)
treec56d0d443c3c76596b90a97e91695a5ed3d4cb34
parent24d1d985d4756f89540b9d6a6a916e36c91cecdf (diff)
Use correct format of listing.
-rw-r--r--session.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/session.c b/session.c
index a042f58..fb2ae37 100644
--- a/session.c
+++ b/session.c
@@ -605,14 +605,15 @@ handle_list_all(struct session *s, struct imsg *imsg)
{
struct list_res *res = imsg->data;
+ res->idx += 1; /* POP3 index is 1 based */
if (res->uidl)
if (strlen(res->u.hash))
- session_reply(s, "%s", res->u.hash);
+ session_reply(s, "%zu %s", res->idx, res->u.hash);
else
goto end;
else
if (res->u.sz)
- session_reply(s, "%zu", res->u.sz);
+ session_reply(s, "%zu %zu", res->idx, res->u.sz);
else
goto end;