- ontty = isatty(fileno(stdout));
-
-#ifdef LBL
- else
- fmt_current_folder = mp;
-#endif
-
- for (msgnum = revflag ? mp->hghsel : mp->lowsel;
- (revflag ? msgnum >= mp->lowsel : msgnum <= mp->hghsel);
- msgnum += (revflag ? -1 : 1)) {
- if (is_selected(mp, msgnum)) {
- if ((in = fopen(cp = m_name(msgnum), "r")) == NULL) {
-#if 0
- if (errno != EACCES)
-#endif
- admonish(cp, "unable to open message");
-#if 0
- else
- printf("%*d unreadable\n",
- DMAXFOLDER, msgnum);
-#endif
- continue;
- }
-
-#ifndef JLR
- if (hdrflag) {
- printf("FOLDER %s\t%s\n", folder, dtimenow(1));
- }
-#endif /* JLR */
-
- /*
- ** Check if message is in any sequence given
- ** by Unseen-Sequence profile entry.
- */
- unseen = 0;
- for (i = 0; i < num_unseen_seq; i++) {
- if (in_sequence(mp, seqnum[i], msgnum)) {
- unseen = 1;
- break;
- }
- }
-
- switch (state = scan(in, msgnum, 0, nfs, width,
- msgnum == mp->curmsg, unseen,
- folder, 0L, 1)) {
- case SCNMSG:
- case SCNENC:
- case SCNERR:
- break;