115 |
|
|
116 |
snprintf(cmd, SMALL_CMD, "%X SELECT INBOX\r\n", tag++); |
snprintf(cmd, SMALL_CMD, "%X SELECT INBOX\r\n", tag++); |
117 |
|
|
118 |
if (!send_command(cmd) && !select_response()) |
return send_command_get_response(cmd); |
119 |
|
} |
120 |
|
|
121 |
|
|
122 |
|
/* |
123 |
|
* IMAP STATUS: requests status of the indicated mailbox. |
124 |
|
*/ |
125 |
|
int imap_status(void) |
126 |
|
{ |
127 |
|
char cmd[MEDIUM_CMD]; |
128 |
|
|
129 |
|
verbose("Client request: STATUS\n"); |
130 |
|
|
131 |
|
snprintf(cmd, MEDIUM_CMD, |
132 |
|
"%X STATUS INBOX (MESSAGES RECENT UNSEEN)\r\n", tag++); |
133 |
|
|
134 |
|
if (!send_command(cmd) && !status_response()) |
135 |
return 0; |
return 0; |
136 |
else |
else |
137 |
return 1; |
return 1; |
138 |
} |
} |
139 |
|
|
140 |
|
|
141 |
/* |
/* |
142 |
* IMAP SEARCH: searches the mailbox for messages that match certain criteria. |
* IMAP SEARCH: searches the mailbox for messages that match certain criteria. |
143 |
*/ |
*/ |