char buffer[BUFSIZ];
if (type == TSUBCWF) {
- /* @folder to +folder */
- snprintf(buffer, sizeof(buffer), "%s/%s", getfolder(1), name);
+ /* convert TSUBCWF to TFOLDER */
+ snprintf(buffer, sizeof(buffer), "%s/%s",
+ getfolder(FCUR), name);
name = m_mailpath(buffer);
packpath(name);
snprintf(buffer, sizeof(buffer), "%s/", m_maildir(""));
/*
-**
+** Return a path name
*/
char *
path(char *name, int type)
char *
pluspath(char *name)
{
- return path(name+1, (*name == '+') ? TFOLDER : TSUBCWF);
+ switch (*name) {
+ case '+':
+ return path(name+1, TFOLDER);
+ case '@':
+ return path(name+1, TSUBCWF);
+ default:
+ return path(name, TFILE);
+ }
}