- if (mode == 0 && !pop_data->cmd_capa) {
- pop_data->cmd_user = 2;
- pop_data->cmd_uidl = 2;
- pop_data->cmd_top = 2;
-
- strfcpy (buf, "AUTH\r\n", sizeof (buf));
- if (pop_fetch_data (pop_data, buf, NULL, fetch_auth, pop_data) == -1)
- return -1;
+ if (mode == 0 && pop_data->cmd_capa == CMD_NOT_AVAILABLE) {
+ pop_data->cmd_user = CMD_UNKNOWN;
+ pop_data->cmd_uidl = CMD_UNKNOWN;
+ pop_data->cmd_top = CMD_UNKNOWN;
+
+ m_strcpy(buf, sizeof(buf), "AUTH\r\n");
+ if (pop_fetch_data (pop_data, buf, NULL, fetch_auth, pop_data) == PQ_NOT_CONNECTED)
+ return PQ_NOT_CONNECTED;