X-Git-Url: http://git.marmaro.de/?a=blobdiff_plain;f=sbr%2Ffmt_scan.c;h=8a8e4c15b409cd6a7a53237d11504e159b6a7391;hb=ced6090a330d3d83d0bce709f756aa3d7d65fea4;hp=14ec48be1170e7a60c5d02dd60d412c0297f9f6b;hpb=337338b404931f06f0db2119c9e145e8ca5a9860;p=mmh diff --git a/sbr/fmt_scan.c b/sbr/fmt_scan.c index 14ec48b..8a8e4c1 100644 --- a/sbr/fmt_scan.c +++ b/sbr/fmt_scan.c @@ -1,10 +1,10 @@ /* - * fmt_scan.c -- format string interpretation - * - * This code is Copyright (c) 2002, by the authors of nmh. See the - * COPYRIGHT file in the root directory of the nmh distribution for - * complete copyright information. - */ +** fmt_scan.c -- format string interpretation +** +** This code is Copyright (c) 2002, by the authors of nmh. See the +** COPYRIGHT file in the root directory of the nmh distribution for +** complete copyright information. +*/ #include #include @@ -39,17 +39,17 @@ extern int fmt_norm; /* defined in sbr/fmt_def.c = AD_NAME */ struct mailname fmt_mnull; /* - * static prototypes - */ +** static prototypes +*/ static int match (char *, char *); static char *get_x400_friendly (char *, char *, int); static int get_x400_comp (char *, char *, char *, int); /* - * test if string "sub" appears anywhere in - * string "str" (case insensitive). - */ +** test if string "sub" appears anywhere in +** string "str" (case insensitive). +*/ static int match (char *str, char *sub) @@ -87,8 +87,8 @@ match (char *str, char *sub) } /* - * copy a number to the destination subject to a maximum width - */ +** copy a number to the destination subject to a maximum width +*/ static void cpnumber(char **dest, int num, unsigned int wid, char fill, size_t n) { int i, c; @@ -118,10 +118,10 @@ cpnumber(char **dest, int num, unsigned int wid, char fill, size_t n) { } /* - * copy string from str to dest padding with the fill character to a size - * of wid characters. if wid is negative, the string is right aligned - * no more than n bytes are copied - */ +** copy string from str to dest padding with the fill character to a size +** of wid characters. if wid is negative, the string is right aligned +** no more than n bytes are copied +*/ static void cptrimmed(char **dest, char *str, unsigned int wid, char fill, size_t n) { int remaining; /* remaining output width available */ @@ -789,17 +789,21 @@ fmt_scan (struct format *format, char *scanl, int width, int *dat) break; case FT_FORMATADDR: - /* hook for custom address list formatting (see replsbr.c) */ + /* + ** hook for custom address list formatting + ** (see replsbr.c) + */ str = formataddr (savestr, str); break; case FT_PUTADDR: - /* output the str register as an address component, - * splitting it into multiple lines if necessary. The - * value reg. contains the max line length. The lit. - * field may contain a string to prepend to the result - * (e.g., "To: ") - */ + /* + ** output the str register as an address component, + ** splitting it into multiple lines if necessary. The + ** value reg. contains the max line length. The lit. + ** field may contain a string to prepend to the result + ** (e.g., "To: ") + */ { unsigned char *lp; char *lastb; @@ -868,10 +872,10 @@ fmt_scan (struct format *format, char *scanl, int width, int *dat) case FT_MYMBOX: /* - * if there's no component, we say true. Otherwise we - * say "true" only if we can parse the address and it - * matches one of our addresses. - */ + ** if there's no component, we say true. Otherwise we + ** say "true" only if we can parse the address and it + ** matches one of our addresses. + */ comp = fmt->f_comp; if (comp->c_mn != &fmt_mnull) mnfree (comp->c_mn); @@ -900,10 +904,12 @@ fmt_scan (struct format *format, char *scanl, int width, int *dat) case FT_ADDTOSEQ: #ifdef LBL - /* If we're working on a folder (as opposed to a file), add the - * current msg to sequence given in literal field. Don't - * disturb string or value registers. - */ + /* + ** If we're working on a folder (as opposed to a + ** file), add the current msg to sequence given + ** in literal field. Don't disturb string or + ** value registers. + */ if (fmt_current_folder) seq_addmsg(fmt_current_folder, fmt->f_text, dat[0], -1); #endif