diff --git a/src/drv_imap.c b/src/drv_imap.c index 85fae81..d3b1447 100644 --- a/src/drv_imap.c +++ b/src/drv_imap.c @@ -1380,7 +1380,11 @@ imap_socket_read( void *aux ) } else /*if (!strcmp( "BAD", arg ))*/ resp = RESP_CANCEL; error( "IMAP command '%s' returned an error: %s %s\n", - !starts_with( cmdp->cmd, -1, "LOGIN", 5 ) ? cmdp->cmd : "LOGIN ", + starts_with( cmdp->cmd, -1, "LOGIN", 5 ) ? + "LOGIN " : + starts_with( cmdp->cmd, -1, "AUTHENTICATE PLAIN", 18 ) ? + "AUTHENTICATE PLAIN " : + cmdp->cmd, arg, cmd ? cmd : "" ); } doresp: