1. 18 Nov, 2016 8 commits
  2. 17 Nov, 2016 3 commits
  3. 16 Nov, 2016 1 commit
  4. 15 Nov, 2016 2 commits
  5. 14 Nov, 2016 13 commits
    • Kevin J. McCarthy's avatar
      Ensure the compressed documentation is always built. · 01938b83
      Kevin J. McCarthy authored
      Add USE_COMPRESSED to makedoc-defs.h so any conditional documentation
      will always be built.
    • Kevin J. McCarthy's avatar
      Compress: check mailbox type if possible when appending. · aab2d75f
      Kevin J. McCarthy authored
      If an append hook isn't defined, then mutt has to decompress the
      mailbox.  In that case, we can check the type of the decompressed
      mailbox instead of defaulting to DefaultMagic.
    • Kevin J. McCarthy's avatar
      Compress: escape single quotes when invoking the compress/decompress commands. · aa8f2cdf
      Kevin J. McCarthy authored
      The format strings are placed in single quotes.  mutt_system() invokes
      sh, so escape the single quotes using bourne-shell syntax: '\''
    • Kevin J. McCarthy's avatar
      Compress: fix check_mailbox and sync_mailbox. · df33e1f1
      Kevin J. McCarthy authored
      Change check_mailbox to delegate to the child_ops->check_mailbox if
      the compressed mailbox has changed.  This allows the mailbox to
      properly recover if both the decompressed mailbox and compressed file
      have changed.
      Change sync_mailbox to call check_mailbox before attempting to sync.
      This will prevent overwriting external changes to the compressed
    • Kevin J. McCarthy's avatar
      Create mx_ops.sync operation. Refactor compress to use the mx_ops.sync. · d3705ea8
      Kevin J. McCarthy authored
      Change compress.sync_mailbox() to lock the compressed mailbox around
      both the tempfile sync and compress operations.  This will prevent
      changes made inbetween the two syncs from being overwritten.
      Thanks to Damien Riegel for his original patch refactoring
      mx_ops.sync, which this patch is partially based upon.
    • Kevin J. McCarthy's avatar
      Compress: pull the lock/unlock operations into the open,close,sync operations. · f46e648f
      Kevin J. McCarthy authored
      Some operations, such as open_append and sync, need an exclusive lock
      across a longer period than a single compress/decompress.  Remove it
      from the execute_command and pull into the outer callers.  Store lock
      information inside compress_info.
      Sync and check_mailbox need more fixes, which will be addressed in
      subsequent patches.
    • Kevin J. McCarthy's avatar
    • Kevin J. McCarthy's avatar
      Compress: add delegate calls to open_append and close mx_ops functions. · 1440451f
      Kevin J. McCarthy authored
      The open_append and close were partially duplicating mbox open_append
      and close operations internally.  Change it to call the actual
      delegate functions instead.
      Inline the open_read() function inside open_mailbox().  Having it
      split improved nothing and just complicated the code (i.e. added
      error-handling checks in open_mailbox() that in reality could not
    • Kevin J. McCarthy's avatar
      Compress: fix several logic and memory bugs. · 203c84f9
      Kevin J. McCarthy authored
      setup_paths leaks memory: realpath is already set in mx_open_mailbox()
      restore_paths is unneeded.  mx_fastclose_mailbox() will free stuff,
      and nothing is looking at the path once we are closing or aborting.
      Make a copy of the hooks.  Otherwise 'unhook *' will leave dangling
      Add compress_info freeing inside mx_fastclose_mailbox().  Only free
      inside compress.c when we want to prevent close() from doing anything.
      close_mailbox() didn't preserve ctx->path on error.
      execute_command() didn't return an error if the mutt_system() command
      mx_open_mailbox_append() should check mutt_comp_can_append() only for
      the case that the mailbox doesn't exist.  When it exists,
      mx_get_magic() has already looked at the file contents before checking
      for matching open_hooks.
      In open_append_mailbox() if no append hook is defined, it should't
      call ci->open() if the mailbox doesn't exist.  It should act just like
      append and create a temporary file.
      check_mailbox() needs more work.  For now, at least have it properly
      close the mailbox on error.
    • Kevin J. McCarthy's avatar
      Compress: remove buffy stats "improvisation". · 4c96c949
      Kevin J. McCarthy authored
      Mutt doesn't support polling compressed mailboxes.  This code creates
      a false impression and dirties mutt_save_message() in the process.  I
      don't like it, so am taking it out.
    • Kevin J. McCarthy's avatar
      Compress: prefix external functions with "mutt_" · 56075cc8
      Kevin J. McCarthy authored
      Also, include compress.h in compress.c so the mx_comp_ops doesn't need
      to be redeclared.
    • Kevin J. McCarthy's avatar
      Compress patch from the neomutt repository. · 9bf6d74e
      Kevin J. McCarthy authored
      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.
    • Damien R.'s avatar
      search muttrc file according to XDG Base Specification (closes #3207) · b17cd673
      Damien R. authored
      First of all, the MUTT_VERSION symbol is now concatenated (when
      possible) at compile time.
      Then, the logic to find the config file has been changed a bit to remove
      unnecessary calls to access(), so now each possible locations for the
      config file is only tested once, and it stops as soon as a valid one has
      been found. So instead of:
        access("/home/dkc/.muttrc-1.7.1", F_OK) = -1 ENOENT (No such file or directory)
        access("/home/dkc/.muttrc", F_OK)       = 0
        access("/home/dkc/.muttrc", F_OK)       = 0
        access("/home/dkc/.muttrc", F_OK)       = 0
        [... Tests for Muttrc ... ]
        access("/home/dkc/.muttrc", F_OK)       = 0
      We now have:
        access("/home/dkc/.muttrc-1.7+13 (f658e517960e)", F_OK) = -1 ENOENT (No such file or directory)
        access("/home/dkc/.muttrc", F_OK)       = 0
      It also cleans up the case where -F is passed on the command line but
      points to a non-existent file by moving the error path closer to the
      actual fail condition.
      Finally, it adds partial support for the XDG Base Directory
      Specification. mutt will now try to locate its config at:
      If XDG_CONFIG_HOME is not set, it will use '~/.config' as a default.
  6. 08 Nov, 2016 4 commits
    • Kevin J. McCarthy's avatar
      Move mbox close-append logic inside mbox_close_mailbox(). · e9de2043
      Kevin J. McCarthy authored
      The mx_fastclose_mailbox() calls mx_ops->close(), which invokes
      Also, close the ctx->fp inside mbox_close_mailbox().  This way, the
      (to be added) compress logic can call the mx_ops->close() instead of
      "knowing" to close the fp before recompressing.
      mx_fastclose_mailbox() will safe_fclose() the fp again, but I'm
      leaving it there just in case I missed a usage of the fp in some other
      part of the code.
      Thanks to Damien Riegel for the original patch.
    • Kevin J. McCarthy's avatar
      Chain %d->%F->%f in the attachment menu. · e494e70b
      Kevin J. McCarthy authored
      Previously, %d would use %f if there was no description set.
      Place the new %F option in between %d and %f.  This way, %d will fall
      back on %F, which will fall back on %f.  This allows the standard
      attachment menu to show d_filename.
      This is useful for forwarding attachments or editing draft files with
      attachments.  In these cases the actual filename is sanitized but the
      attachment name is preserved in d_filename.
    • Damien R.'s avatar
      compose: add operation to rename an attachment · a3c97365
      Damien R. authored
      As opposed to rename-file, which actually renames the underlying file
      of the attachment, rename-attachment puts a value in d_filename, which
      is used in the Content-Disposition header.
    • Damien R.'s avatar
      attach_format: add new %F placeholder · e8b85603
      Damien R. authored
      This new placeholder allows to print the attachment name as it will be
      seen on the recipient side.
  7. 03 Nov, 2016 4 commits
  8. 01 Nov, 2016 1 commit
  9. 23 Oct, 2016 4 commits