Age | Commit message (Collapse) | Author | Files |
|
|
|
|
|
The bug spotted by Christophe Deleuze in
https://savannah.gnu.org/patch/?10439
* libproto/mailer/smtp_capa.c (mu_smtp_capa_test): Issue ehlo only when
in the corresponding state.
Return MU_ERR_NOENT if the requested capability is not found, including
the case when the capability array is null because of one-line ehlo
response or because plain SMTP is in use.
* libproto/mailer/smtp_capa_itr.c (mu_smtp_capa_iterator): Likewise.
* libproto/mailer/smtp_ehlo.c (mu_smtp_ehlo): Fail if not in the
MU_SMTP_EHLO state. Set MU_SMTP_MAIL on success.
* libproto/mailer/smtp_gsasl.c (_mu_smtp_gsasl_auth): Reset stat to
MU_SMTP_EHLO.
* libproto/mailer/smtp_starttls.c (mu_smtp_starttls): Likewise.
|
|
|
|
|
|
This function deallocates resources allocated by mu_dbm_firstkey
function. It should be used when breaking from a loop iterating
over all keys in the database.
* include/mailutils/dbm.h (mu_dbm_impl): New field: _dbm_break
(mu_dbm_break): New function.
* libmu_dbm/break.c: New file.
* libmu_dbm/Makefile.am (libmu_dbm_la_SOURCES): Add break.c
* libmu_dbm/berkeley.c (_bdb_close): Close cursor, if available.
(_bdb_break): New method.
* libmu_dbm/gdbm.c (_gdbm_break): New method.
|
|
|
|
|
|
* include/mailutils/server.h (mu_m_server_config_default_fp): New data type.
(mu_m_server_set_config_default): New prototype.
* libmailutils/server/msrv.c (_mu_m_server): New field: config_default.
(mu_m_server_set_config_default): New function.
(mu_m_server_listen): If config_default is initialized, call it to
initialize the pconf structure.
* imap4d/imap4d.c (imap4d_connection): Don't reset idle_timeout and
imap4d_transcript.
(imap4d_config_default): New function.
(main): Initialize the server's config_default function.
* pop3d/apop.c (apop_ok): New function.
* pop3d/pop3d.c (pop3d_mainloop): Don't include timestamp in the
banner greeting if APOP database is not available.
(pop3d_config_default): New function.
(main): Initialize the server's config_default function.
* pop3d/pop3d.h (apop_ok): New prototype.
|
|
* libmailutils/base/filesafety.c (mu_file_safety_check): Accept symbolic
links. Fix memory leak.
|
|
determined otherwise
|
|
* NEWS: Version 3.16.90
* configure.ac: Likewise.
* imap4d/imap4d.c (main): Use PORT_IMAP4 constant.
* imap4d/imap4d.h (PORT_IMAP4,PORT_IMAP4S): New defines.
* imap4d/starttls.c (starttls_server_check): Derive the tls mode
from the port used or from the global tls mode.
* include/mailutils/sockaddr.h (mu_sockaddr_get_port): New proto.
* libmailutils/sockaddr/Makefile.am: Add port.c
* libmailutils/sockaddr/port.c: New file.
* mu/libexec/shell.c (readline): Minor change.
* pop3d/cmd.c (stls_server_check): Derive the tls mode
from the port used or from the global tls mode.
* pop3d/pop3d.c (main): Use PORT_POP3 constant.
* pop3d/pop3d.h (PORT_POP3, PORT_POP3S): New defines.
|
|
* mu/libexec/shell.c [!WITH_READLINE] (readline): Remove static
qualifiers.
|
|
|
|
* configure.ac: Remove check for gethostbyname
* include/mailutils/util.h: Fix comment.
* imap4d/util.c: Use getaddrinfo.
* libmailutils/base/hostname.c: Likewise.
* libmailutils/sockaddr/fromnode.c: Likewise.
* libmu_auth/virtual.c: Use getnameinfo.
|
|
* NEWS: Update.
* libmu_scm/tests/testsuite.at: Fix improper use of AT_TESTED.
* maint/release.mk (GNUPLOAD): New variable.
* configure.ac: New maintainer option --with-gnupload.
|
|
* configure.ac: Require autoconf 2.71, automake 1.16.2
Don't use obsolete macros.
Drop support for Berkeley DB 2.
* gint: Upgrade.
* gnulib: Upgrade.
* am/db2.m4: Remove. Support for bdb2 withdrawn.
* libmu_dbm/berkeley.c: Drop support for bdb2.
* am/config_paths.m4: Don't use obsolete autoconf macros.
* am/debug.m4: Likewise.
* am/enable.m4: Likewise.
* am/gsasl.m4: Likewise.
* am/gssapi.m4: Likewise.
* am/ipv6.m4: Likewise.
* am/tls.m4: Likewise.
* mail/mail.h (mailvar_value): Rename bool to
boolean to avoid eventual conflicts. All uses changed.
* comsat/comsat.c: Remove the uses of RETSIGTYPE.
* examples/echosrv.c: Likewise.
* imap4d/bye.c: Likewise.
* imap4d/imap4d.c: Likewise.
* imap4d/imap4d.h: Likewise.
* imap4d/signal.c: Likewise.
* lib/muaux.h: Likewise.
* lib/signal.c: Likewise.
* libmailutils/mailer/progmailer.c: Likewise.
* libmailutils/server/msrv.c: Likewise.
* libmu_sieve/extensions/spamd.c: Likewise.
* mh/mhn.c: Likewise.
* mh/prompter-tty.c: Likewise.
* mh/sortm.c: Likewise.
* pop3d/pop3d.h: Likewise.
* pop3d/signal.c: Likewise.
|
|
Patch proposed by Dave Love <Dave.Love@manchester.ac.uk>
* mail/util.c (util_get_charset): Check if charset is not NULL
before strdup'ing it.
|
|
|
|
* NEWS: Document changes.
* configure.ac: Version 3.15.90
* libmailutils/stdstream/strerr.c (mu_stdstream_strerr_setup): Don't
destroy mu_strerr unconditionally, use mu_stream_unref.
* frm/common.c (format_field_align): Initialize local variable.
* lib/mailcap.c (mime_context_get_temp_file): Issue diagnostics
on error.
(expand_string): Return -1 if the temp file creation fails.
(create_filter,run_test,run_mailcap): Improve error checking.
* libmailutils/base/fgetpwent.c (mu_fgetpwent_r): Fix use of
uninitialized variables.
* libmailutils/mailbox/msgqlines.c (mu_message_quick_lines): Likewise.
* libmailutils/mime/mimeitr.c (itrdup): Initialize the allocated
value with zeroes.
* libmailutils/stream/prog_stream.c (start_program_filter): Improve
error checking.
* libmailutils/tests/t-streamshift.c: Use typecasts when printing
mu_off_t values.
* libmailutils/url/set-service.c (mu_url_set_service): Initialize port.
* libproto/imap/fetch.c (_fill_response): Fix possible use of
uninitialized variable.
* libproto/maildir/maildir.c (maildir_message_name_parse): Initialize
endval.
* libproto/mailer/prog.c (url_to_argv): Translate wordsplit error
code to the mailutils one.
* libproto/mbox/message.c (env_to_stream): Make sure ref->date is
null-terminated.
* libproto/pop/pop3_response.c (mu_pop3_get_response): Don't check for
non-null receiver before calling mu_cpystr: it copes with the case by
itself.
* libproto/pop/pop3_top.c (mu_pop3_top): Always initialize status.
* mail/escape.c (escape_help): Likewise.
* mail/util.c (util_do_command): Remove unnecessaty conditional. Upon
successful return from mu_vasnprintf cmd is guaranteed to have a non-
null value.
* mda/lib/script.c (mda_filter_message): Bail out if changing to the
user dir fails.
* mh/mhn.c (com_send): Fix allowed user responses.
* mu/libexec/smtp.c (next_name_from_file): Fix the use of uninitialized
variables.
|
|
* libmailutils/stream/wordwrap.c (mu_wordwrap_stream): New
field: overflow.
(line_not_empty): New auxiliary function.
(_wordwrap_flush_line,_wordwrap_write)
(_wordwrap_flush): Handle line overflow.
* libmailutils/tests/wordwrap03.at: More tests.
|
|
* libmu_auth/tlsfdstr.c (_tlsfd_done): Don't close borrowed descriptors.
(mu_tlsfd_stream_create): Avoid both fds being closed on error.
|
|
* libmailutils/base/mutil.c (mutil_parse_field_map): Fix an attempt
to free a memory area that hasn't been allocated. Not so critical:
the bug would be hit only if mu_assoc_install failed (which means
out of memory condition).
|
|
* mh/folder.c (action_pack): Return immediately if the mailbox is
empty.
|
|
|
|
stream size
This addresses the problem mentioned in the previous commit.
* libmailutils/stream/rdcache_stream.c (rdcache_size): Return
MU_ERR_INFO_UNAVAILABLE if mu_stream_size returns EAGAIN, EINTR,
ENOSYS, or EINPROGRESS.
* libmailutils/stream/stream.c (mu_stream_seterr): Handle
MU_ERR_INFO_UNAVAILABLE same way as ENOSYS et al.
* libmailutils/stream/streamcpy.c (mu_stream_copy_wcb): Same
handling for: EAGAIN, EINTR, ENOSYS, EINPROGRESS, and
MU_ERR_INFO_UNAVAILABLE.
* mh/msgchk.c (checkmail): Likewise.
|
|
Until now, read cache stream incorrectly updated its size when it
should not. This happened when the stream had cached some data,
then had been rewound and a read operation performed on it.
* libmailutils/stream/rdcache_stream.c
(mu_rdcache_stream_max_memory_size): Remove unused global.
(rdcache_read): Fix stream size computation.
(rdcache_size): Return cached size only if EOF was hit on transport stream,
otherwise return its size. This means that depending on whether the stream
was already cached or not, the call to mu_stream_size on rdcache stream may
return ENOSYS or success.
* libmailutils/tests/t-rdcache.c: New test program.
* libmailutils/tests/Makefile.am: Build t-rdcache.
* libmailutils/tests/testsuite.at: Run t-rdcache.
|
|
* libproto/mbox/tests/append.at: Strip leading whitespace from the
wc output.
* libproto/mbox/tests/lastmsg.at: Likewise.
* mda/mda/tests/forward.at: Likewise.
|
|
* NEWS: Raise version number
* configure.ac: Raise version number. Increase shared library
current interface number.
|
|
* imap4d/imap4d.c (namespace_section_parser): Return error on
invalid or empty namespace name.
|
|
|
|
support parts
* mail/mail.h (MSG_ALLOWPART): New flag.
* mail/msgset.y: Allow message parts only if MSG_ALLOWPART is set.
Rewrite as a reentrant parser.
* mail/decode.c: Allow message parts in sets.
* mail/write.c: Likewise.
|
|
* imap4d/auth_gsasl.c (auth_gsasl): Initialize stream[1],
unless set after return from ioctl.
* libmailutils/stream/fltstream.c (filter_ctl): If both streams
are supplied for MU_IOCTL_OP_SET, combine them into an iostream
prior to setting the transport pointer.
|
|
* imap4d/imap4d.c (test_mode): Three-state. Initialize to "undef".
(imap4d_mainloop): Don't alter test_mode here.
(main): Detect test_mode value unless already set earlier.
|
|
* libmailutils/server/msrv.c (set_signal): Catch errors.
(_mu_m_server.sigtab): Increase size by one. Slot 0 is not used.
(mu_m_server_begin,mu_m_server_restore_signals): Enumerate signals
starting from 1.
|
|
* mh/tests/fmtcomp.at (unclosed control): Reflect changed wording
in parsers produced by bison 3.8.2
|
|
* libmailutils/stream/streamcpy.c (mu_stream_copy_nl): Append an extra
\n only unless the last character in stream is a newline. Always append
an empty line at the end.
* libproto/mbox/message.c (mboxrd_message_copy_with_uid): use regular
mu_stream_copy, instead of mu_stream_copy_nl.
* mda/tests/input.msg: Remove empty line at the end.
* mda/lmtpd/tests/lmtpd.at: Ensure expout ends with an empty line.
* mda/mda/tests/forward.at: Likewise.
* mda/mda/tests/mda.at: Likewise.
* mda/putmail/tests/putmail.at: Likewise.
|
|
|
|
See 451ca485. Patch by Kurt Hackenberg.
|
|
|
|
* configure.ac: Version 3.14.90
* NEWS: Version 3.14.90
* libproto/mbox/mboxrd.c (scan_message_finalize): Take decrement value (n)
without additional corrections. All uses changed.
(mailbox_append_message): Fix padding.
* libproto/mbox/message.c (_msg_stream_setup)
(mboxrd_message_body_scan,_msg_body_setup): Don't count terminating empty
line as part of the message body.
* libproto/mbox/tests/lastmsg.at: New test.
* libproto/mbox/tests/Makefile.am: Add new files.
* libproto/mbox/tests/testsuite.at: Likewise.
* libproto/mbox/tests/append.at: Test appending to partially terminated
mailboxes.
* libproto/mbox/tests/body.at: Fix expected octet and line counts.
* libproto/mbox/tests/attr.at: Likewise.
* libproto/mbox/tests/autodetect.at: Likewise.
* libproto/mbox/tests/count.at: Likewise.
* libproto/mbox/tests/env.at: Likewise.
* libproto/mbox/tests/notify.at: Likewise.
* libproto/mbox/tests/qget.at: Likewise.
* comsat/tests/testsuite.at: Likewise.
* imap4d/tests/IDEF0956.at: Likewise.
* imap4d/tests/fetch.at: Likewise.
* libmu_scm/tests/mailbox-append-message.at: Likewise.
* libmu_scm/tests/mailbox-expunge.at: Likewise.
* libmu_scm/tests/mailbox-get-message.at: Likewise.
* libmu_scm/tests/mailbox-iterate.at: Likewise.
* libtests/mime.at: Likewise.
* mail/tests/align.at: Likewise.
* mail/tests/hold.at: Likewise.
* mail/tests/nohome.at: Likewise.
* mail/testsuite/mail/Followup.exp
* mail/testsuite/mail/Reply.exp
* mail/testsuite/mail/folder.exp
* mail/testsuite/mail/followup.exp
* mail/testsuite/mail/read.exp
* mail/testsuite/mail/reply.exp
* mail/testsuite/mail/tag.exp
* mail/testsuite/mail/z.exp
* pop3d/testsuite/pop3d/read.exp
* readmsg/tests/all.at: Likewise.
* readmsg/tests/hdr.at: Likewise.
* readmsg/tests/nohdr.at: Likewise.
* readmsg/tests/twomsg.at: Likewise.
* readmsg/tests/weed.at: Likewise.
* sieve/tests/redirect.at: Likewise.
* sieve/tests/reject.at: Likewise.
|
|
If called with NULL as its fourth argument (size_t *pread), the function
should return error if unable to read the requested number of bytes.
* libmailutils/stream/stream.c (mu_stream_read): If pread is NULL
and less than the requested number of bytes has been read, return
MU_ERR_READ.
* libmailutils/tests/t-streamshift.c (stream_verify): Fix size calculation.
|
|
* include/mailutils/assoc.h (MU_ASSOC_LRU): New flag.
(mu_assoc_pop, mu_assoc_shift): Change signature: second argument
is char **.
* libmailutils/base/assoc.c (mu_assoc_install_ref2): Maintain LRU
ordering, if so requested.
mu_assoc_pop, mu_assoc_shift): Change type of the second argument to
char **. Unless it is NULL, store there a copy of the key.
* libmu_sieve/sieve-priv.h (mu_sieve_machine): New member: mailboxes.
* libmu_sieve/actions.c (sieve_action_fileinto): Maintain a table of
output mailboxes. Keep each mailbox open for as long as possible.
If running out of open files, close the least recently used mailbox
and retry.
* libmu_sieve/sieve-gram.y (mu_sieve_machine_destroy): Destroy the
mailbox table.
|
|
Until now both mboxrd and dotmail preferred mmap over unistd-based
I/O. This improved performance when reading and updating mailboxes,
but deteriorated it when operating in append mode. To improve
performance in append mode, a new function (mu_mailbox_stream_create)
is introduced, which selects the underlying stream for the mailbox
file based on the requested open mode and the currentstatus of the
file itself. Both mboxrd and dotmail use this function to initialize
mailbox stream.
* include/mailutils/stream.h (mu_mailbox_stream_create): New proto.
* libmailutils/stream/Makefile.am (libstream_la_SOURCES): Add mailbox_stream.c
* libmailutils/stream/mailbox_stream.c: New file.
* libproto/dotmail/dotmail.c (dotmail_mailbox_init_stream): Use
mu_mailbox_stream_create.
* libproto/mbox/mboxrd.c (mboxrd_mailbox_init_stream): Likewise.
|
|
* libmailutils/filter/fromrd.c (_fromrd_decoder): Don't switch state
if '\n' is received while in S_BOL state.
|
|
Bug reported by Kurt Hackenberg, see:
https://lists.gnu.org/archive/html/bug-mailutils/2022-01/msg00001.html
* libmailutils/filter/qpflt.c (_qp_decoder): Fix calculation of the
number of consumed input characters.
|
|
* libproto/mbox/mboxrd.c (mboxrd_tracker_sync): If mailbox becomes
empty, reset all uid-related fields. It is especially important to
reset x_imapbase_len, otherwise expunging all messages in the mailbox
followed by appending a new message would cause mboxrd_flush_unlocked
in line 1670 to overwrite a random fragment of the newly created message.
|
|
* libproto/dotmail/dotmail.c (dotmail_mailbox_init_stream): Don't retry
opening the file if it mu_mapfile_stream_create returned ENOENT, i.e.
file does not exist and MU_STREAM_CREAT was not specified.
Use same flags in both attempts.
(dotmail_open): Check return from dotmail_mailbox_init_stream.
(dotmail_tracker_sync): If mailbox becomes empty, reset all uid-related
fields to 0.
|
|
|
|
|