From: Pierre Habouzit Date: Fri, 25 May 2007 22:03:58 +0000 (+0200) Subject: remove the stupid macro, we are big kids enough to write NULL, NULL. X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=commitdiff_plain;h=97e1d274dfbeb8b4a5da3f2b68fb66f96b7739d3 remove the stupid macro, we are big kids enough to write NULL, NULL. Signed-off-by: Pierre Habouzit --- diff --git a/browser.c b/browser.c index 4ba6e19..f6ebc08 100644 --- a/browser.c +++ b/browser.c @@ -706,8 +706,8 @@ static int file_tag (MUTTMENU * menu, int n, int m) return ff->tagged - ot; } -void _mutt_select_file (char *f, ssize_t flen, int flags, char ***files, - int *numfiles) +void mutt_select_file (char *f, ssize_t flen, int flags, char ***files, + int *numfiles) { char buf[_POSIX_PATH_MAX]; char prefix[_POSIX_PATH_MAX] = ""; diff --git a/lib-ui/curs_lib.c b/lib-ui/curs_lib.c index 936edda..937ada4 100644 --- a/lib-ui/curs_lib.c +++ b/lib-ui/curs_lib.c @@ -398,8 +398,8 @@ int _mutt_enter_fname (const char *prompt, char *buf, ssize_t blen, else if (ch.ch == '?') { mutt_refresh (); buf[0] = 0; - _mutt_select_file (buf, blen, M_SEL_FOLDER | (multiple ? M_SEL_MULTI : 0), - files, numfiles); + mutt_select_file (buf, blen, M_SEL_FOLDER | (multiple ? M_SEL_MULTI : 0), + files, numfiles); *redraw = REDRAW_FULL; } else { diff --git a/lib-ui/enter.c b/lib-ui/enter.c index 0d61f2d..1005365 100644 --- a/lib-ui/enter.c +++ b/lib-ui/enter.c @@ -455,8 +455,8 @@ int _mutt_enter_string (char *buf, size_t buflen, int y, int x, if (tempbuf && templen == state->lastchar - i && !memcmp (tempbuf, state->wbuf + i, (state->lastchar - i) * sizeof (wchar_t))) { - mutt_select_file (buf, buflen, - (flags & M_EFILE) ? M_SEL_FOLDER : 0); + mutt_select_file(buf, buflen, flags & M_EFILE ? M_SEL_FOLDER : 0, + NULL, NULL); set_option (OPTNEEDREDRAW); if (*buf) replace_part (state, i, buf); @@ -514,9 +514,9 @@ int _mutt_enter_string (char *buf, size_t buflen, int y, int x, || (tempbuf && templen == state->lastchar && !memcmp (tempbuf, state->wbuf, state->lastchar * sizeof (wchar_t)))) { - _mutt_select_file (buf, buflen, - ((flags & M_EFILE) ? M_SEL_FOLDER : 0) | - (multiple ? M_SEL_MULTI : 0), files, numfiles); + mutt_select_file(buf, buflen, + ((flags & M_EFILE) ? M_SEL_FOLDER : 0) | + (multiple ? M_SEL_MULTI : 0), files, numfiles); set_option (OPTNEEDREDRAW); if (*buf) { mutt_pretty_mailbox (buf); diff --git a/main.c b/main.c index eb309b8..90d5e1a 100644 --- a/main.c +++ b/main.c @@ -667,7 +667,8 @@ int main (int argc, char **argv) exit (1); } folder[0] = 0; - mutt_select_file (folder, sizeof (folder), M_SEL_FOLDER | M_SEL_BUFFY); + mutt_select_file(folder, sizeof(folder), M_SEL_FOLDER | M_SEL_BUFFY, + NULL, NULL); if (!folder[0]) { mutt_endwin (NULL); exit (0); diff --git a/mutt.h b/mutt.h index 2bf0141..512e9a4 100644 --- a/mutt.h +++ b/mutt.h @@ -191,7 +191,7 @@ enum { #define SENDRESEND (1<<6) #define SENDNEWS (1<<7) -/* flags to _mutt_select_file() */ +/* flags to mutt_select_file() */ #define M_SEL_BUFFY (1<<0) #define M_SEL_MULTI (1<<1) #define M_SEL_FOLDER (1<<2) diff --git a/protos.h b/protos.h index a8f57ec..31ae4ed 100644 --- a/protos.h +++ b/protos.h @@ -80,8 +80,7 @@ void mutt_safe_path (char *s, ssize_t l, address_t * a); void mutt_save_path (char *s, ssize_t l, address_t * a); void mutt_select_fcc (char *, ssize_t, HEADER *); -#define mutt_select_file(A,B,C) _mutt_select_file(A,B,C,NULL,NULL) -void _mutt_select_file (char *, ssize_t, int, char ***, int *); +void mutt_select_file (char *, ssize_t, int, char ***, int *); void mutt_message_hook (CONTEXT *, HEADER *, int); void _mutt_set_flag (CONTEXT *, HEADER *, int, int, int);