| 487 | } |
| 488 | |
| 489 | static char *next_arg(char **s) |
| 490 | { |
| 491 | char *ret; |
| 492 | |
| 493 | if (!s || !*s) |
| 494 | return NULL; |
| 495 | while (isspace((unsigned char) **s)) |
| 496 | (*s)++; |
| 497 | if (!**s) { |
| 498 | *s = NULL; |
| 499 | return NULL; |
| 500 | } |
| 501 | if (**s == '"') { |
| 502 | ++*s; |
| 503 | ret = *s; |
| 504 | *s = strchr(*s, '"'); |
| 505 | } else { |
| 506 | ret = *s; |
| 507 | while (**s && !isspace((unsigned char) **s)) |
| 508 | (*s)++; |
| 509 | } |
| 510 | if (*s) { |
| 511 | if (**s) |
| 512 | *(*s)++ = 0; |
| 513 | if (!**s) |
| 514 | *s = NULL; |
| 515 | } |
| 516 | return ret; |
| 517 | } |
| 518 | |
| 519 | static struct imap_cmd *issue_imap_cmd(struct imap_store *ctx, |
| 520 | struct imap_cmd_cb *cb, |
no outgoing calls
no test coverage detected