1bc19d43aee56384ebd2d7c491041ba844c56e2a
[mmh] / h / prototypes.h
1
2 /*
3  * prototypes.h -- various prototypes
4  */
5
6 /*
7  * missing system prototypes
8  */
9 #ifndef HAVE_TERMCAP_H
10 extern int tgetent (char *bp, char *name);
11 extern int tgetnum (char *id);
12 extern int tgetflag (char *id);
13 extern char *tgetstr (char *id, char **area);
14 extern char *tgoto (char *cm, int destcol, int destline);
15 extern int tputs (char *cp, int affcnt, int (*outc) (int));
16 #endif
17
18 /*
19  * prototype from config.h
20  */
21 char *etcpath(char *);
22
23 /*
24  * prototypes from the nmh subroutine library
25  */
26 void adios (char *, char *, ...) NORETURN;
27 void admonish (char *, char *, ...);
28 void advertise (char *, char *, char *, va_list);
29 void advise (char *, char *, ...);
30 void ambigsw (char *, struct swit *);
31 int atooi(char *);
32 char **brkstring (char *, char *, char *);
33 int check_charset (char *, int);
34 int client(char *, char *, char *, int, int);
35 void closefds(int);
36 char *concat (char *, ...);
37 int context_del (char *);
38 char *context_find (char *);
39 int context_foil (char *);
40 void context_read (void);
41 void context_replace (char *, char *);
42 void context_save (void);
43 char *copy (char *, char *);
44 char **copyip (char **, char **, int);
45 void cpydata (int, int, char *, char *);
46 void cpydgst (int, int, char *, char *);
47 int decode_rfc2047 (char *, char *, size_t);
48 void discard (FILE *);
49 int default_done (int);
50 int ext_hook(char *, char *, char *);
51 int fdcompare (int, int);
52 int folder_addmsg (struct msgs **, char *, int, int, int, int, char *);
53 int folder_delmsgs (struct msgs *, int, int);
54 void folder_free (struct msgs *);
55 int folder_pack (struct msgs **, int);
56 struct msgs *folder_read (char *);
57 struct msgs *folder_realloc (struct msgs *, int, int);
58 int gans (char *, struct swit *);
59 char **getans (char *, struct swit *);
60 int getanswer (char *);
61 char **getarguments (char *, int, char **, int);
62 char *get_charset();
63 char *getcpy (char *);
64 char *getfolder(int);
65 int lkclose(int, char*);
66 int lkfclose(FILE *, char *);
67 FILE *lkfopen(char *, char *);
68 int lkopen(char *, int, mode_t);
69 int m_atoi (char *);
70 char *m_backup (char *);
71 int m_convert (struct msgs *, char *);
72 char *m_draft (char *, char *, int, int *);
73 void m_eomsbr (int (*)(int));
74 int m_getfld (int, unsigned char *, unsigned char *, int, FILE *);
75 int m_gmprot (void);
76 char *m_maildir (char *);
77 char *m_mailpath (char *);
78 char *m_name (int);
79 int m_putenv (char *, char *);
80 char *m_scratch (char *, char *);
81 char *m_tmpfil (char *);
82 char *m_mktemp(const char *, int *, FILE **);
83 char *m_mktemp2(const char *, const char *, int *, FILE **);
84 void m_unknown(FILE *);
85 int makedir (char *);
86 char *nmh_getpass(const char *);
87 char *norm_charmap(char *);
88 char *new_fs (char *, char *, char *);
89 char *path(char *, int);
90 int peekc(FILE *ib);
91 int pidwait (pid_t, int);
92 int pidstatus (int, FILE *, char *);
93 char *pluspath(char *);
94 void print_help (char *, struct swit *, int);
95 void print_sw (char *, struct swit *, char *, FILE *);
96 void print_version (char *);
97 void push (void);
98 char *pwd (void);
99 char *r1bindex(char *, int);
100 void readconfig (struct node **, FILE *, char *, int);
101 int refile (char **, char *);
102 void ruserpass(char *, char **, char **);
103 int remdir (char *);
104 int seq_addmsg (struct msgs *, char *, int, int, int);
105 int seq_addsel (struct msgs *, char *, int, int);
106 char *seq_bits (struct msgs *);
107 int seq_delmsg (struct msgs *, char *, int);
108 int seq_delsel (struct msgs *, char *, int, int);
109 int seq_getnum (struct msgs *, char *);
110 char *seq_list (struct msgs *, char *);
111 int seq_nameok (unsigned char *);
112 void seq_print (struct msgs *, char *);
113 void seq_printall (struct msgs *);
114 void seq_read (struct msgs *);
115 void seq_save (struct msgs *);
116 void seq_setcur (struct msgs *, int);
117 void seq_setprev (struct msgs *);
118 void seq_setunseen (struct msgs *, int);
119 int showfile (char **, char *);
120 int smatch(char *, struct swit *);
121 char *snprintb (char *, size_t, unsigned, char *);
122 int ssequal (char *, char *);
123 int stringdex (char *, char *);
124 char *trimcpy (unsigned char *);
125 int unputenv (char *);
126 int uprf (char *, char *);
127 int vfgets (FILE *, char **);
128 char *write_charset_8bit (void);
129
130 #ifdef RPATHS
131 int get_returnpath (char *, int, char *, int);
132 #endif
133
134 /*
135  * prototypes for compatibility functions in library
136  */
137 #ifndef HAVE_SNPRINTF_PROTOTYPE
138 int snprintf (char *, size_t, const char *, ...);
139 int vsnprintf (char *, size_t, const char *, va_list);
140 #endif
141
142 int mh_strcasecmp (const char *s1, const char *s2);
143 int strncasecmp (const char *s1, const char *s2, size_t n);
144
145
146 /*
147  * some prototypes for address parsing system
148  * (others are in addrsbr.h)
149  */
150 char *LocalName(void);
151 char *SystemName(void);
152 char *OfficialName(char *);
153
154 /*
155  * prototypes for some routines in uip
156  */
157 int annotate (char *, char *, char *, int, int, int, int);
158 void annolist(char *, char *, char *, int);
159 void annopreserve(int);
160 int distout (char *, char *, char *);
161 void replout (FILE *, char *, char *, struct msgs *, int,
162         int, char *, char *, char *);
163 int sendsbr (char **, int, char *, struct stat *, int, char *, int);
164 int what_now (char *, int, int, char *, char *,
165         int, struct msgs *, char *, int, char *);
166