mutt stable branch with some hacks
1/*
2 * Copyright (C) 1996-2002,2010,2016 Michael R. Elkins <me@mutt.org>
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
17 */
18
19WHERE void (*mutt_error) (const char *, ...);
20WHERE void (*mutt_message) (const char *, ...);
21
22WHERE CONTEXT *Context;
23
24WHERE char Errorbuf[STRING];
25WHERE char AttachmentMarker[STRING];
26WHERE char ProtectedHeaderMarker[STRING];
27
28#if defined(DL_STANDALONE) && defined(USE_DOTLOCK)
29WHERE char *MuttDotlock;
30#endif
31
32WHERE ADDRESS *EnvFrom;
33WHERE ADDRESS *From;
34
35WHERE char *AliasFile;
36WHERE char *AliasFmt;
37WHERE char *AssumedCharset;
38WHERE char *AttachSep;
39WHERE char *Attribution;
40WHERE char *AttributionLocale;
41WHERE char *AttachCharset;
42WHERE char *AttachFormat;
43#ifdef USE_AUTOCRYPT
44WHERE char *AutocryptAcctFormat;
45WHERE char *AutocryptDir;
46WHERE char *AutocryptSignAs; /* This is used in crypt-gpgme.c */
47WHERE char *AutocryptDefaultKey; /* Used for postponing messages */
48#endif
49WHERE char *Charset;
50WHERE char *ComposeFormat;
51WHERE char *ConfigCharset;
52WHERE char *ContentType;
53WHERE char *DefaultHook;
54WHERE char *DateFmt;
55WHERE char *DisplayFilter;
56WHERE char *DsnNotify;
57WHERE char *DsnReturn;
58WHERE char *Editor;
59WHERE char *EscChar;
60WHERE char *FolderFormat;
61WHERE char *ForwardAttrIntro;
62WHERE char *ForwardAttrTrailer;
63WHERE char *ForwFmt;
64WHERE char *Fqdn;
65WHERE char *HdrFmt;
66WHERE char *HistFile;
67WHERE char *Homedir;
68WHERE char *Hostname;
69#ifdef USE_IMAP
70WHERE char *ImapAuthenticators;
71WHERE char *ImapDelimChars;
72WHERE char *ImapHeaders;
73WHERE char *ImapLogin;
74WHERE char *ImapOauthRefreshCmd;
75WHERE char *ImapPass;
76WHERE char *ImapUser;
77#endif
78WHERE char *Inbox;
79WHERE char *Ispell;
80WHERE char *MailcapPath;
81WHERE char *Maildir;
82#if defined(USE_IMAP) || defined(USE_POP)
83WHERE char *MessageCachedir;
84#endif
85#if USE_HCACHE
86WHERE char *HeaderCache;
87#if HAVE_GDBM || HAVE_DB4
88WHERE long HeaderCachePageSize;
89#endif /* HAVE_GDBM || HAVE_DB4 */
90#endif /* USE_HCACHE */
91WHERE char *MarkMacroPrefix;
92WHERE char *MhFlagged;
93WHERE char *MhReplied;
94WHERE char *MhUnseen;
95WHERE char *MimeTypeQueryCmd;
96WHERE char *MsgFmt;
97
98#ifdef USE_SOCKET
99WHERE char *Preconnect;
100WHERE char *Tunnel;
101WHERE short NetInc;
102#endif /* USE_SOCKET */
103
104#ifdef MIXMASTER
105WHERE char *Mixmaster;
106WHERE char *MixEntryFormat;
107#endif
108
109WHERE char *Muttrc;
110WHERE char *Outbox;
111WHERE char *Pager;
112WHERE char *PagerFmt;
113WHERE char *PipeSep;
114#ifdef USE_POP
115WHERE char *PopAuthenticators;
116WHERE short PopCheckTimeout;
117WHERE char *PopHost;
118WHERE char *PopOauthRefreshCmd;
119WHERE char *PopPass;
120WHERE char *PopUser;
121#endif
122WHERE char *PostIndentString;
123WHERE char *Postponed;
124WHERE char *PostponeEncryptAs;
125WHERE char *Prefix;
126WHERE char *PrintCmd;
127WHERE char *ProtHdrSubject;
128WHERE char *NewMailCmd;
129WHERE char *QueryCmd;
130WHERE char *QueryFormat;
131WHERE char *Realname;
132WHERE short SearchContext;
133WHERE char *SendCharset;
134WHERE char *SendMultipartAltFilter;
135WHERE char *Sendmail;
136WHERE char *Shell;
137#ifdef USE_SIDEBAR
138WHERE char *SidebarDelimChars;
139WHERE char *SidebarDividerChar;
140WHERE char *SidebarFormat;
141WHERE char *SidebarIndentString;
142#endif
143WHERE char *Signature;
144WHERE char *SimpleSearch;
145#if USE_SMTP
146WHERE char *SmtpAuthenticators;
147WHERE char *SmtpPass;
148WHERE char *SmtpOauthRefreshCmd;
149WHERE char *SmtpUrl;
150#endif /* USE_SMTP */
151WHERE char *Spoolfile;
152WHERE char *SpamSep;
153#if defined(USE_SSL)
154WHERE char *SslCertFile;
155WHERE char *SslClientCert;
156WHERE char *SslEntropyFile;
157WHERE char *SslCiphers;
158#ifdef USE_SSL_GNUTLS
159WHERE short SslDHPrimeBits;
160WHERE char *SslCACertFile;
161#endif
162#endif
163WHERE mbchar_table *StChars;
164WHERE char *Status;
165WHERE char *Tempdir;
166WHERE mbchar_table *Tochars;
167WHERE char *TrashPath;
168WHERE char *TSStatusFormat;
169WHERE char *TSIconFormat;
170WHERE short TSSupported;
171WHERE char *Username;
172WHERE char *Visual;
173
174WHERE char *CurrentFolder;
175WHERE char *LastFolder;
176
177
178WHERE const char *ReleaseDate;
179
180WHERE HASH *Groups;
181WHERE HASH *ReverseAlias;
182WHERE HASH *AutoSubscribeCache;
183
184WHERE LIST *AutoViewList;
185WHERE LIST *AlternativeOrderList;
186WHERE LIST *AttachAllow;
187WHERE LIST *AttachExclude;
188WHERE LIST *InlineAllow;
189WHERE LIST *InlineExclude;
190WHERE LIST *HeaderOrderList;
191WHERE LIST *Ignore;
192WHERE LIST *MailtoAllow;
193WHERE LIST *MimeLookupList;
194WHERE LIST *UnIgnore;
195
196WHERE RX_LIST *Alternates;
197WHERE RX_LIST *UnAlternates;
198WHERE RX_LIST *MailLists;
199WHERE RX_LIST *UnMailLists;
200WHERE RX_LIST *SubscribedLists;
201WHERE RX_LIST *UnSubscribedLists;
202WHERE REPLACE_LIST *SpamList;
203WHERE RX_LIST *NoSpamList;
204WHERE REPLACE_LIST *SubjectRxList;
205
206
207/* bit vector for boolean variables */
208#ifdef MAIN_C
209unsigned char Options[(OPTMAX + 7)/8];
210#else
211extern unsigned char Options[];
212#endif
213
214/* bit vector for the yes/no/ask variable type */
215#ifdef MAIN_C
216unsigned char QuadOptions[(OPT_MAX*2 + 7) / 8];
217#else
218extern unsigned char QuadOptions[];
219#endif
220
221WHERE unsigned short Counter;
222
223WHERE short ConnectTimeout;
224WHERE short ErrorHistSize;
225WHERE short HistSize;
226WHERE short MenuContext;
227WHERE short PagerContext;
228WHERE short PagerIndexLines;
229WHERE short ReadInc;
230WHERE short ReflowWrap;
231WHERE short SaveHist;
232WHERE short SendmailWait;
233WHERE short SleepTime INITVAL (1);
234WHERE short TimeInc;
235WHERE short Timeout;
236WHERE short Wrap;
237WHERE short WrapHeaders;
238WHERE short WriteInc;
239
240WHERE short ScoreThresholdDelete;
241WHERE short ScoreThresholdRead;
242WHERE short ScoreThresholdFlag;
243
244#ifdef USE_SIDEBAR
245WHERE short SidebarWidth;
246WHERE LIST *SidebarWhitelist;
247#endif
248
249#ifdef USE_IMAP
250WHERE long ImapFetchChunkSize;
251WHERE short ImapKeepalive;
252WHERE short ImapPipelineDepth;
253WHERE short ImapPollTimeout;
254#endif
255
256/* flags for received signals */
257WHERE SIG_ATOMIC_VOLATILE_T SigAlrm;
258WHERE SIG_ATOMIC_VOLATILE_T SigInt;
259WHERE SIG_ATOMIC_VOLATILE_T SigWinch;
260
261WHERE int CurrentMenu;
262
263WHERE ALIAS *Aliases;
264WHERE LIST *UserHeader;
265
266/*-- formerly in pgp.h --*/
267WHERE REGEXP PgpGoodSign;
268WHERE REGEXP PgpDecryptionOkay;
269WHERE char *PgpDefaultKey;
270WHERE char *PgpSignAs;
271WHERE long PgpTimeout;
272WHERE char *PgpEntryFormat;
273WHERE char *PgpClearSignCommand;
274WHERE char *PgpDecodeCommand;
275WHERE char *PgpVerifyCommand;
276WHERE char *PgpDecryptCommand;
277WHERE char *PgpSignCommand;
278WHERE char *PgpEncryptSignCommand;
279WHERE char *PgpEncryptOnlyCommand;
280WHERE char *PgpImportCommand;
281WHERE char *PgpExportCommand;
282WHERE char *PgpVerifyKeyCommand;
283WHERE char *PgpListSecringCommand;
284WHERE char *PgpListPubringCommand;
285WHERE char *PgpGetkeysCommand;
286
287/*-- formerly in smime.h --*/
288WHERE char *SmimeDefaultKey;
289WHERE char *SmimeSignAs;
290WHERE long SmimeTimeout;
291WHERE char *SmimeCertificates;
292WHERE char *SmimeKeys;
293WHERE char *SmimeCryptAlg;
294WHERE char *SmimeCALocation;
295WHERE char *SmimeVerifyCommand;
296WHERE char *SmimeVerifyOpaqueCommand;
297WHERE char *SmimeDecryptCommand;
298WHERE char *SmimeSignCommand;
299WHERE char *SmimeDigestAlg;
300WHERE char *SmimeSignOpaqueCommand;
301WHERE char *SmimeEncryptCommand;
302WHERE char *SmimeGetSignerCertCommand;
303WHERE char *SmimePk7outCommand;
304WHERE char *SmimeGetCertCommand;
305WHERE char *SmimeImportCertCommand;
306WHERE char *SmimeGetCertEmailCommand;
307
308
309
310
311#ifdef MAIN_C
312const char * const Weekdays[] = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" };
313const char * const Months[] = { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "ERR" };
314
315const char * const BodyTypes[] = { "x-unknown", "audio", "application", "image", "message", "model", "multipart", "text", "video" };
316const char * const BodyEncodings[] = { "x-unknown", "7bit", "8bit", "quoted-printable", "base64", "binary", "x-uuencoded" };
317#else
318extern const char * const Weekdays[];
319extern const char * const Months[];
320#endif
321
322#ifdef MAIN_C
323/* so that global vars get included */
324#include "mx.h"
325#include "mutt_regex.h"
326#include "buffy.h"
327#include "sort.h"
328#include "mutt_crypt.h"
329#include "reldate.h"
330#endif /* MAIN_C */