]> diplodocus.org Git - nmh/blob - h/prototypes.h
Replaced reference to mktemp(3) with mkstemp(3) in
[nmh] / h / prototypes.h
1
2 /*
3 * prototypes.h -- various prototypes
4 */
5
6 /*
7 * missing system prototypes
8 */
9 #if ! defined(HAVE_TERMCAP_H) && ! defined (HAVE_NCURSES_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
27 struct msgs_array;
28
29 void adios (char *, char *, ...) NORETURN;
30 void admonish (char *, char *, ...);
31 void advertise (char *, char *, char *, va_list);
32 void advise (char *, char *, ...);
33 char **argsplit (char *, char **, int *);
34 void argsplit_msgarg (struct msgs_array *, char *, char **);
35 void argsplit_insert (struct msgs_array *, char *, char **);
36 void arglist_free (char *, char **);
37 void ambigsw (char *, struct swit *);
38 int atooi(char *);
39 char **brkstring (char *, char *, char *);
40 int check_charset (char *, int);
41 int client(char *, char *, char *, int, int);
42 void closefds(int);
43 char *concat (const char *, ...);
44 int context_del (char *);
45 char *context_find (char *);
46 int context_foil (char *);
47 void context_read (void);
48 void context_replace (char *, char *);
49 void context_save (void);
50 char *copy (const char *, char *);
51 char **copyip (char **, char **, int);
52 void cpydata (int, int, char *, char *);
53 void cpydgst (int, int, char *, char *);
54 char *cpytrim (const char *);
55 int decode_rfc2047 (char *, char *, size_t);
56 void discard (FILE *);
57 int default_done (int);
58 void escape_display_name (char *, size_t);
59 void escape_local_part (char *, size_t);
60 int ext_hook(char *, char *, char *);
61 int fdcompare (int, int);
62 int folder_addmsg (struct msgs **, char *, int, int, int, int, char *);
63 int folder_delmsgs (struct msgs *, int, int);
64 void folder_free (struct msgs *);
65 int folder_pack (struct msgs **, int);
66 struct msgs *folder_read (char *);
67 struct msgs *folder_realloc (struct msgs *, int, int);
68 int gans (char *, struct swit *);
69 char **getans (char *, struct swit *);
70 #ifdef READLINE_SUPPORT
71 char **getans_via_readline (char *, struct swit *);
72 #endif /* READLINE_SUPPORT */
73 int getanswer (char *);
74 char **getarguments (char *, int, char **, int);
75 char *get_charset(void);
76 char *getcpy (char *);
77 char *get_default_editor(void);
78 char *getfolder(int);
79 int lkclose(int, char*);
80 int lkfclose(FILE *, char *);
81 FILE *lkfopen(char *, char *);
82 int lkopen(char *, int, mode_t);
83 int m_atoi (char *);
84 char *m_backup (char *);
85 int m_convert (struct msgs *, char *);
86 char *m_draft (char *, char *, int, int *);
87 void m_eomsbr (m_getfld_state_t, int (*)(int));
88 void m_getfld_state_reset (m_getfld_state_t *);
89 void m_getfld_state_destroy (m_getfld_state_t *);
90 void m_getfld_track_filepos (m_getfld_state_t *, FILE *);
91 int m_getfld (m_getfld_state_t *, char[NAMESZ], char *, int *, FILE *);
92 int m_gmprot (void);
93 char *m_maildir (char *);
94 char *m_mailpath (char *);
95 char *m_name (int);
96 int m_putenv (char *, char *);
97 int m_rand (unsigned char *, size_t);
98 char *m_mktemp(const char *, int *, FILE **);
99 char *m_mktemp2(const char *, const char *, int *, FILE **);
100 void m_unknown(m_getfld_state_t *, FILE *);
101 int makedir (char *);
102 char *message_id (time_t, int);
103 char *nmh_getpass(const char *);
104 char *norm_charmap(char *);
105 char *new_fs (char *, char *, char *);
106 char *path(char *, int);
107 int peekc(FILE *ib);
108 int pidwait (pid_t, int);
109 int pidstatus (int, FILE *, char *);
110 char *pluspath(char *);
111 void print_help (char *, struct swit *, int);
112 void print_sw (char *, struct swit *, char *, FILE *);
113 void print_version (char *);
114 void push (void);
115 char *pwd (void);
116 char *r1bindex(char *, int);
117 void readconfig (struct node **, FILE *, char *, int);
118 int refile (char **, char *);
119 void ruserpass(char *, char **, char **);
120 int remdir (char *);
121 void scan_detect_mbox_style (FILE *);
122 void scan_finished ();
123 void scan_eom_action (int (*)());
124 void scan_reset_m_getfld_state ();
125 int seq_addmsg (struct msgs *, char *, int, int, int);
126 int seq_addsel (struct msgs *, char *, int, int);
127 char *seq_bits (struct msgs *);
128 int seq_delmsg (struct msgs *, char *, int);
129 int seq_delsel (struct msgs *, char *, int, int);
130 int seq_getnum (struct msgs *, char *);
131 char *seq_list (struct msgs *, char *);
132 int seq_nameok (char *);
133 void seq_print (struct msgs *, char *);
134 void seq_printall (struct msgs *);
135 void seq_read (struct msgs *);
136 void seq_save (struct msgs *);
137 void seq_setcur (struct msgs *, int);
138 void seq_setprev (struct msgs *);
139 void seq_setunseen (struct msgs *, int);
140 int showfile (char **, char *);
141 int smatch(char *, struct swit *);
142 char *snprintb (char *, size_t, unsigned, char *);
143 int ssequal (char *, char *);
144 int stringdex (char *, char *);
145 char *trimcpy (char *);
146 int unputenv (char *);
147 int uprf (char *, char *);
148 int vfgets (FILE *, char **);
149 char *write_charset_8bit (void);
150
151 int mh_strcasecmp (const char *s1, const char *s2);
152 int strncasecmp (const char *s1, const char *s2, size_t n);
153
154
155 /*
156 * some prototypes for address parsing system
157 * (others are in addrsbr.h)
158 */
159 char *LocalName(int);
160 char *SystemName(void);
161
162 /*
163 * prototypes for some routines in uip
164 */
165 int annotate (char *, char *, char *, int, int, int, int);
166 void annolist(char *, char *, char *, int);
167 void annopreserve(int);
168 void clear_screen(void);
169 void m_pclose(void);
170 int make_intermediates(char *);
171 int mhl(int, char **);
172 int mhlsbr(int, char **, FILE *(*)(char *));
173 int distout (char *, char *, char *);
174 void replout (FILE *, char *, char *, struct msgs *, int,
175 int, char *, char *, char *, int);
176 int sc_hardcopy(void);
177 int sc_length(void);
178 int sc_width(void);
179 int build_form (char *, char *, int *, char *, char *, char *, char *,
180 char *, char *);
181 int sendsbr (char **, int, char *, char *, struct stat *, int, char *, int);
182 int SOprintf (char *, ...);
183 int what_now (char *, int, int, char *, char *,
184 int, struct msgs *, char *, int, char *, int);
185 int WhatNow(int, char **);
186 int writeBase64aux(FILE *, FILE *);
187 int writeBase64 (unsigned char *, size_t, unsigned char *);