- mutt_mktemp (tempfile);
- if (!(f = safe_fopen (tempfile, "w+"))) {
- mutt_perror (tempfile);
+ f = m_tempfile(tempfile, sizeof(tempfile), NONULL(Tempdir), NULL);
+ if (!f) {
+ mutt_error(_("Could not create temporary file"));
- snprintf (buf, sizeof (buf), "string_list_t %d\r\n", h->refno);
+ snprintf (buf, sizeof (buf), "LIST %d\r\n", h->refno);
ret = pop_query (pop_data, buf, sizeof (buf));
if (ret == PQ_OK) {
sscanf (buf, "+OK %d %ld", &idx, &length);
ret = pop_query (pop_data, buf, sizeof (buf));
if (ret == PQ_OK) {
sscanf (buf, "+OK %d %ld", &idx, &length);
bar.msg = _("Fetching message...");
mutt_progress_bar (&bar, 0);
bar.msg = _("Fetching message...");
mutt_progress_bar (&bar, 0);
char *url, *p;
int i, delanswer, last = 0, msgs, bytes, rset = 0;
pop_query_status ret;
char *url, *p;
int i, delanswer, last = 0, msgs, bytes, rset = 0;
pop_query_status ret;
- strcpy (url, "pop://"); /* __STRCPY_CHECKED__ */
- p = strchr (url, '\0');
+ plen -= m_strcpy(url, plen, "pop://");
+ p += plen;