- case 'd':
- if (!optional)
- {
- snprintf (fmt, sizeof (fmt), "%%%sd", prefix);
- snprintf (buf, buflen, fmt, Context ? Context->deleted : 0);
- }
- else if (!Context || !Context->deleted)
- optional = 0;
- break;
+ case 'B':
+ snprintf (fmt, sizeof (fmt), "%%%ss", prefix);
+ if (Context && Context->compressinfo && Context->realpath) {
+ if ((p = strrchr (Context->realpath, '/')))
+ m_strcpy(tmp, sizeof(tmp), p + 1);
+ else
+ m_strcpy(tmp, sizeof(tmp), Context->realpath);
+ }
+ else
+ if (Context && Context->path) {
+ if ((p = strrchr (Context->path, '/')))
+ m_strcpy(tmp, sizeof(tmp), p + 1);
+ else
+ m_strcpy(tmp, sizeof(tmp), Context->path);
+ }
+ else
+ m_strcpy(tmp, sizeof(tmp), _("no mailbox"));
+ snprintf (buf, buflen, fmt, tmp);
+ break;