X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=init.c;h=c9442ce8350865f20b02ec7f28b81937d890a2f4;hp=9b9346e155ffac2a93b35c8d00afb764a190f24e;hb=1d76b29d79137330c8f42d489fe3f67a23f2390b;hpb=b94ae1245c98907bffbbbefaf6feb53f1ac80234 diff --git a/init.c b/init.c index 9b9346e..c9442ce 100644 --- a/init.c +++ b/init.c @@ -319,18 +319,6 @@ static int rx_from_string (struct option_t* dst, const char* val, return (1); } -static void magic_to_string (char* dst, ssize_t dstlen, - struct option_t* option) { - const char* s = NULL; - switch (option->data) { - case M_MBOX: s = "mbox"; break; - case M_MH: s = "MH"; break; - case M_MAILDIR: s = "Maildir"; break; - default: s = "unknown"; break; - } - snprintf (dst, dstlen, "%s=%s", option->option, s); -} - static int magic_from_string (struct option_t* dst, const char* val, char *errbuf, ssize_t errlen) { @@ -367,7 +355,6 @@ static struct { { DT_QUAD, quad_to_string, quad_from_string }, { DT_SORT, sort_to_string, sort_from_string }, { DT_RX, rx_to_string, rx_from_string }, - { DT_MAGIC, magic_to_string, magic_from_string }, }; @@ -1099,7 +1086,6 @@ static int parse_set (BUFFER * tmp, BUFFER * s, unsigned long data, } else if (DTYPE (option->type) == DT_STR || DTYPE (option->type) == DT_PATH || - DTYPE (option->type) == DT_MAGIC || DTYPE (option->type) == DT_NUM || DTYPE (option->type) == DT_SORT || DTYPE (option->type) == DT_RX) @@ -1559,23 +1545,6 @@ int mutt_var_value_complete (char *buffer, ssize_t len, int pos) (*((short *)option->data) & SORT_REVERSE) ? "reverse-" : "", (*((short *)option->data) & SORT_LAST) ? "last-" : "", p); } - else if (DTYPE (option->type) == DT_MAGIC) { - const char *p; - switch (DefaultMagic) { - case M_MBOX: - p = "mbox"; - break; - case M_MH: - p = "MH"; - break; - case M_MAILDIR: - p = "Maildir"; - break; - default: - p = "unknown"; - } - m_strcpy(tmp, sizeof(tmp), p); - } else if (DTYPE (option->type) == DT_BOOL) m_strcpy(tmp, sizeof(tmp), option(option->data) ? "yes" : "no"); else