imap: Fixed response check for SEARCH command
authorAlex McLellan <alex.mclellan@zephirlidar.com>
Tue, 13 Aug 2013 12:13:20 +0000 (13:13 +0100)
committerSteve Holme <steve_holme@hotmail.com>
Mon, 19 Aug 2013 09:23:14 +0000 (10:23 +0100)
Adding this line allows libcurl to return the server response when
performing a search command via a custom request.

lib/imap.c

index 13a11d0..a8d9519 100644 (file)
@@ -307,7 +307,8 @@ static bool imap_endofresp(struct connectdata *conn, char *line, size_t len,
            (strcmp(imap->custom, "STORE") ||
             !imap_matchresp(line, len, "FETCH")) &&
            strcmp(imap->custom, "SELECT") &&
-           strcmp(imap->custom, "EXAMINE")))
+           strcmp(imap->custom, "EXAMINE") &&
+           strcmp(imap->custom, "SEARCH")))
           return FALSE;
         break;