summaryrefslogtreecommitdiffstats
path: root/main.c
AgeCommit message (Collapse)Author
2020-12-30Merge branch 'stable'Kevin McCarthy
2020-12-30Bump copyright notices.Kevin McCarthy
I'll run the update tool on source files in master a bit later.
2020-11-22Allow debugging without debug file rotation.David Champion
start_debug() takes a boolean indicating whether to rotate debug files. The -d option allows a negative number. If negative, debug files are not rotated. The debug level is the absolute value. This is useful for continuously watching (e.g. tail -f) the .muttdebug0 file.
2020-08-26Remove always true conditional (#if 1)Remco Rijnders
2020-06-04Add other headers to written Protected Headers.Kevin McCarthy
In order to avoid $edit_headers, <resend-message>, or other places setting env->date and inadvertantly generating a wrong Date header, store the "protected headers" generated date header in the sctx, in addition to mime_headers. I initially removed env->date setting from mutt_parse_rfc822_line(), thinking it a more elegant solution, but unfortunately protected headers reading needs it to be there. We don't currently print or compare the headers, but might wish to in the future. Explicitly pass in a date parameters to mutt_write_rfc822_header() to make each caller conscious of where the date is coming from.
2020-05-07Add L10N strings to exit_handler().Kevin McCarthy
Since gettext() is not safe in the handler, cache them in advance.
2020-05-02Update 'mutt -v' copyright date.Kevin McCarthy
Since the phrase contains "and others" the developers judged it was correct to increase the year number.
2020-03-31Create crypt glue cleanup method.Kevin McCarthy
Create stub classic smime and cleanup functions, which will be used in the next commit.
2020-03-31Convert LastSaveFolder to buffer.Kevin McCarthy
2020-02-29Enable backgrounding a single <mail> function.Kevin McCarthy
Backgrounding exits to the index menu. Re-invoking <mail> will resume the backgrounded session, if one exists, otherwise start a new session. This is just to get basic support going. Multiple background edits, a landing page, a background compose menu list will be added next.
2020-02-29Rename ci_send_message() to mutt_send_message().Kevin McCarthy
This fits the current naming conventions. There are a few other "ci_" prefixed functions, but there's no need to tackle all those changes right now.
2020-02-28Create send.h header.Kevin McCarthy
This will hold the send context, so we may as well pull the prototypes into the header file too.
2020-01-11Update copyrights to 2020.Kevin McCarthy
2019-11-01Create multipart/mixed helpers.Kevin McCarthy
Since we will be dealing with multipart/alternative, we need the helpers to be a bit more specific. We need to distinguish a top-level multipart/alternative from a multipart/mixed created because of attachments.
2019-10-09Convert main() to use buffers for paths.Kevin McCarthy
Convert fpath (used for checking and creating $folder. Convert expanded_infile and tempfile which are used for the -i,-H, and -E options. We allocate buffers, rather than use the pool, because they are used for the duration of the compose/send operation.
2019-08-03Add initial autocrypt account setup.Kevin McCarthy
Generate gpg key and add account record to the database.
2019-08-03Add database and schema initialization.Kevin McCarthy
Add mutt_mkdir() library function supporting recursive mkdir.
2019-08-03Initial autoconf and makefile setup for autocrypt.Kevin McCarthy
2019-04-07Change main() folder to be BUFFER.Kevin McCarthy
This affects the -f, -y, and -Z options directly.
2019-03-13browser.c: Convert LastDir and LastDirBackup to BUFFER.Kevin McCarthy
Add a cleanup method call to main to free the BUFFERS. Add mutt_buffer_concat_path() buffer helper function.
2019-01-05Merge branch 'stable'Kevin McCarthy
2019-01-05Update copyright for the next stable release.Kevin McCarthy
2019-01-04Clean up formatting.Kevin McCarthy
Add spaces after if, else, while, for, switch. Unify the brace placement style. The vast majority of the code uses Allman style so convert the relatively few K&R braces over.
2019-01-04Clean up code indentation.Kevin McCarthy
These are mostly automated changes corresponding to the emacs settings: (c-set-style "linux") (setq c-basic-offset 2) (c-set-offset 'case-label '+) Most of the code follows the convention: (add-to-list 'c-cleanup-list 'space-before-funcall) but this is not enforced by this indentation cleanup. Also, I personally dislike tabs, so I have: (setq-default indent-tabs-mode nil) in my own configuration. However I have no desire to change every line just for that effect. So this cleanup does nothing about the mix issue. Some of the secondary files (e.g. regex.c) have been skipped. I've also skipped crypt-gpgme.c, because I need to think about that file. Werner Koch and the GnuPG team contributed most it, and it follows the Gnu indentation settings. It should probably be made uniform with Mutt, but I don't want to discourage future GnuPG contribution to the file. I manually reverted a few unsightly cleanups, and added a few tweeks when I saw things that could be improved.
2018-12-31Remove trailing whitespace.Kevin McCarthy
The result of find . -name "*.[ch]" -exec emacs -batch {} \ --eval="(progn (delete-trailing-whitespace) (and (buffer-modified-p) (save-buffer)))" \;
2018-12-25Finish protected header write support.Kevin McCarthy
Write out the protected headers when writing the mime header part. Hide protected subjects with $crypt_protected_headers_subject, for outgoing, postponed, and fcc'ed messages. Don't hide in postponed and fcc'ed if $crypt_protected_headers_read isn't set. Add a few missing cases where mime_headers needed to be cleaned up on error. Remove the protected headers for $fcc_clear.
2018-12-25Add a new mode for mutt_write_rfc822_header().Kevin McCarthy
Convert the mode parameter to an enum, to make the code a bit more readable.
2018-10-06Add buffer pool functions.Kevin McCarthy
Also add a few helper functions: mutt_buffer_clear(), mutt_buffer_strcpy(), and a macro mutt_b2s to grab the buffer data as a const char *.
2018-09-14Free queries and alias_queries before exiting.Kevin McCarthy
2018-07-28Move exit cleanup in main() to end of function.Kevin McCarthy
Route exits to the same place to ensure uniform cleanup. Message printing is a bit of a mess, but for now, try to keep the exact same behavior.
2018-07-28Fix -z and -Z options to work with IMAP.Kevin McCarthy
-Z did not work if $imap_passive was set (the default). I think using the option implies the desire to open a new connection and check buffy at startup, so temporarily turn it off during the buffy. -z was not hooked up for IMAP. Change it to call imap_status(). This also requires $imap_passive be unset, so temporarily turn the option off too.
2018-06-03add feature file monitoring with Linux inotifyGT
2018-05-01Update copyright notices.Kevin McCarthy
2018-04-15Add libidn2 supportMatej Muzila
2018-02-06Add a blank line between the compile options and the contact info for mutt -vVincent Lefevre
2018-02-04Put gitlab issues url on a separate line.Kevin McCarthy
This removes the need to use brackets, and makes it easier for translations to fit within 80 columns. Thanks to Derek Martin for the suggested wording, and to Vincent Lefèvre for proofreading and noticing a small error.
2018-01-31Merge branch 'stable'Kevin McCarthy
2018-01-31Add delimiters around gitlab issues URL.Kevin McCarthy
Without the delimiters, the period can be easily inadvertantly copied as part of the URL.
2018-01-17Merge branch 'stable'Kevin McCarthy
2018-01-17Change bug reporting URL to gitlab issues.Kevin McCarthy
2018-01-16Split Copyright and Thanks in help output.Olaf Hering
The Copyright string is changing often, and its content is obvious. It does not need translation. The remaining string can be translated. This change avoids a stale translation once one of the years change. Signed-off-by: Olaf Hering <olaf@aepfle.de>
2017-12-17manually touch atime when reading a mbox fileAdam Borowski
The only common use of atime left is local mail agents leaving a mark on mbox file after the mail has been read. And, since POSIX-2008, it is possible to use futimens() to alter atime even on filesystems mounted with noatime. There's no extra cost for doing this on when atime updates are enabled: the inode will be dirty already.
2017-11-28Update copyright notices.Kevin McCarthy
2017-06-01Enable TEXTDOMAINDIR override to make translation testing easier.TAKAHASHI Tamotsu
If set, TEXTDOMAINDIR will point to a translation directory instead of using the mutt installation directory.
2017-06-01Fix "format string is not a string literal" warnings. (closes #3949)TAKAHASHI Tamotsu
Mutt calls msgfmt with '-c' to verify that translation format strings match, but it is still safer to indirect strings with no formatting through %s.
2017-03-18Fix conststrings type mismatches. (closes #3926)Kevin McCarthy
The generation programs for conststrings.c: txt2c.c and txt2c.sh, specified the resultant types as "unsigned char[]" while main.c declared them as "const char[]". txt2.c generates 0xXX hex codes for each individual character, thus the "unsigned" definition. With link-time optimization, some versions of gcc notice the mismatch and emit a warning. Change the declarations to match the definitions and cast to char[] when they are used.
2017-01-28Improve the label completion hash table usage.Kevin McCarthy
Move the hash table inside the Context. Hook message arrival/deletion to update the label hash. Change the label hash to strdup keys. Use hash_find_elem when updating the counter, to reduce unnecessary add/delete operations.
2017-01-28Adds label completion.David Champion
A global label hash is added, to which labels are added as they're parsed from a mailbox file or edited manually by the user. Reference counts are kept in the hash table so that unused labels are removed from available completions. Completion is available in the label editor only, but it may be feasible to add for search expressions if the preceding text ends with '~y'.
2016-12-11Add setenv/unsetenv commands.David Champion
These can be used to add and remove environment variables passed to children via mutt_system(). Commited by Kevin McCarthy with some cleanup.
2016-11-13Compress patch from the neomutt repository.Kevin McCarthy
With the following changes: - po/de.po changes trimmed to just the compress additions. - Move the sample muttrc to contrib, and add it to the Makefile.am so it is distributed. Remove the sample vimrc. - Remove extra fluff from manual. Thanks to Roland Rosenfeld for the original patch, and to the NeoMutt team for their work cleaning up the patch.