2021-11-30 12:47:52 +0200 Aki Tuomi <aki.tuomi@open-xchange.com> (476cd46418)

    Release v2.3.17.1


M	NEWS
M	configure.ac

2021-12-01 14:46:04 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (0c9435763f)

    dsync: Fix -I max-size to actually be the max-size rather than min-size

    The -I max-size parameter was supposed to be used to skip mails that are 
    larger than max-size. Instead, it skipped mails that were smaller.

M	src/doveadm/dsync/dsync-mailbox-import.c

2021-11-09 13:42:24 +0100 Timo Sirainen <timo.sirainen@open-xchange.com> (285c210669)

    man: Add missing parameters to doveadm-sync


M	doc/man/doveadm-sync.1.in

2021-11-30 18:02:14 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (24e815548a)

    dsync: Remove -D parameter that disables syncing mailbox renames

    It hasn't been necessary for a long time, and its behavior seems to be 
    broken.

M	src/doveadm/doveadm-dsync.c
M	src/doveadm/dsync/dsync-brain-mailbox-tree.c
M	src/doveadm/dsync/dsync-brain-private.h
M	src/doveadm/dsync/dsync-brain.c
M	src/doveadm/dsync/dsync-brain.h
M	src/doveadm/dsync/dsync-ibc-stream.c

2021-11-09 13:41:37 +0100 Timo Sirainen <timo.sirainen@open-xchange.com> (6aad6150f3)

    dsync: Add back various missing parameters

    Also add them to the usage string.

    Broken by 5676c510bfa9217df05e9b7cb000ae3554d66f22

M	src/doveadm/doveadm-dsync.c

2021-11-01 08:33:49 -0400 Timo Sirainen <timo.sirainen@open-xchange.com> (8414c38c5c)

    master: Use MASTER_SERVICE_FLAG_DISABLE_SSL_SET

    This prevents startup failures if ssl_ca has a large number of certificates.

    Broken by 36ff43f1a9aff8594d08f791e77ea13390fd569f

M	src/master/main.c

2021-11-01 08:33:14 -0400 Timo Sirainen <timo.sirainen@open-xchange.com> (e3f629cc69)

    lib-master: Add MASTER_SERVICE_FLAG_DISABLE_SSL_SET


M	src/lib-master/master-service-settings.c
M	src/lib-master/master-service.h

2021-10-28 17:07:39 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (6177ba5e30)

    dsync: Add back missing -T parameter

    Broken by 5676c510bfa9217df05e9b7cb000ae3554d66f22

M	src/doveadm/doveadm-dsync.c

2021-10-27 12:06:10 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (f10f77c401)

    lib-ssl-iostream: Fix assert-crash when OpenSSL returns syscall error
    without errno

    Incomplete fix in f41874b3dec541478a85275698a91f089f537df2

    Fixes: Panic: file istream-openssl.c: line 51 (i_stream_ssl_read_real):
    assertion failed: (errno != 0)

M	src/lib-ssl-iostream/iostream-openssl.c

2021-09-28 12:40:29 +0300 Aki Tuomi <aki.tuomi@open-xchange.com> (e2aa53df5b)

    NEWS: Add news for 2.3.17


M	NEWS

2021-09-29 00:04:29 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (720e1be3cb)

    lib-storage: When search parses message headers, deinitialize the parsing
    properly

    index_mail_parse_header() was being called only for the actual headers. This
    prevented it from being called with hdr=NULL to indicate that the parsing is
    finished and should be deinitialized. Move the index_mail_parse_header() to
    be called earlier so it's called also with hdr=NULL.

    Not deinitilizing the parsing could have caused assert-crashes later on in 
    some situations.

    Fixes: Panic: file index-mail-headers.c: line 667
    (index_mail_get_raw_headers): assertion failed:
    (mail->mail.mail.lookup_abort >= MAIL_LOOKUP_ABORT_NOT_IN_CACHE) Panic: file
    ../../../src/lib/array.h: line 244 (array_idx_i): assertion failed: (idx <
    array->buffer->used / array->element_size) Panic: file index-mail.c: line
    1203 (index_mail_parse_body_finish): assertion failed: (!success)

M	src/lib-storage/index/index-search.c

2021-10-13 11:45:05 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (2134197b48)

    lib-index: Add mail_index_alloc_cache_find()


M	src/lib-index/mail-index-alloc-cache.c
M	src/lib-index/mail-index-alloc-cache.h

2021-10-07 18:11:00 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (6e73b50e29)

    maildir: Fix crash when closing a mailbox that isn't open

    This could have happened at least with virtual plugin.

M	src/lib-storage/index/maildir/maildir-storage.c

2021-10-06 15:38:55 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (46a907a3f6)

    imap: Fix handling client initialization error

    It should send "OK Logged in" + BYE, not PREAUTH.

    Broken by 714ff4342e39e309ff184905cd2f714def6177a3

M	src/imap/main.c

2021-10-08 16:02:04 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (d1b06bcf8c)

    imap: Move client_add_input() content to calling functions


M	src/imap/main.c

2021-10-08 15:57:50 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (feafbd3ba6)

    imap: Move IMAPLOGINTAG environment handling

    It can only happen with stdio clients when they don't have CLIENT_INPUT, so
    it makes more sense to exist in the calling function.

M	src/imap/main.c

2021-10-06 15:43:09 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (6f664bd5a4)

    imap-login: proxy: Don't forward untagged BYE responses to the client

    It will just cause confusion, especially when connections are retried. It
    could end up looking like:

    x login user pass
    * BYE Internal error occurred. Refer to server log for more information.
    * BYE Internal error occurred. Refer to server log for more information.
    * BYE Internal error occurred. Refer to server log for more information.
    * BYE Internal error occurred. Refer to server log for more information. x
    NO [UNAVAILABLE] Account is temporarily unavailable.

M	src/imap-login/imap-proxy.c

2021-10-08 15:53:21 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (a424d2e7e0)

    lib-storage: mail_storage_service_lookup() - Fix memory leak when returning
    -2

    This was also visible as event leaks.

M	src/lib-storage/mail-storage-service.c

2021-10-07 14:52:12 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (5e0e7128d9)

    virtual: Fix assert-crash when backend mbox mailbox is deleted while virtual
    mailbox is open

    The code wrongly thought that metadata lookup couldn't fail because it was 
    already successfully looked up. But the backend storage could still try to 
    refresh the mailbox to verify whether it still exists or not, and fail if it
    was deleted.

    This seems to have affected only the mbox mailbox format.

    Broken by 710346bcb884b464c8ed128870fdc1999c13dfd3

M	src/plugins/virtual/virtual-sync.c

2021-09-30 15:38:23 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (0846f2ddd9)

    lib-http: test-http-client-errors - Revert previous retry changes

    The real bug is found now, so the previous fix attempt isn't useful. Reverts
    ed1264368a5435c3080871380156978a8951fe26

M	src/lib-http/test-http-client-errors.c

2021-09-30 15:32:24 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (3cdb47ab0c)

    lib-http: test-http-client-errors - Reset USR1 notification signal between
    tests

    The "connection refused" test already set the signal as being received, 
    which caused the "connection refused backoff" test to randomly fail since it 
    thought the signal was immediately received.

M	src/lib-http/test-http-client-errors.c

2021-10-06 13:20:12 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (50fc60fd8e)

    lib: Fix data_stack_get_alloc_size() and data_stack_get_used_size()

    It only worked correctly if data stack hadn't been grown. This resulted in
    wrong numbers in the data_stack_grow event.

M	src/lib/data-stack.c

2021-10-01 15:08:45 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (1cee336aab)

    virtual: Fix leaking mailboxes if virtual mailbox can't be opened

    Fixes also a crash at deinit: Panic: file mail-user.c: line 232
    (mail_user_deinit): assertion failed: ((*user)->refcount == 1)

M	src/plugins/virtual/virtual-storage.c

2021-10-04 11:14:04 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (83316e996f)

    driver-pgsql: Fix error leak


M	src/lib-sql/driver-pgsql.c

2021-09-30 18:42:08 +0300 sergey.kitov <sergey.kitov@open-xchange.com> (8da67de232)

    stats: Remove metric from stats dump, when removing dynamically.


M	src/stats/stats-metrics.c

2021-09-29 14:58:22 +0300 sergey.kitov <sergey.kitov@open-xchange.com> (9e48e55247)

    stats: Improve error message for doveadm stats add.


M	src/stats/client-reader.c

2021-09-29 14:57:34 +0300 sergey.kitov <sergey.kitov@open-xchange.com> (1d8f9abfb9)

    stats: Check if metric already exists when adding dynamically.


M	src/stats/stats-metrics.c

2021-10-01 10:42:16 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (f356f9b075)

    driver-cassandra: Fix prepared statement pool leak


M	src/lib-sql/driver-cassandra.c

2021-09-25 00:48:12 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (ae5b70a0d7)

    lib: istream-concat - Prevent inheriting SIZE_MAX max buffer size from
    parent streams.

    Only when all parent streams have SIZE_MAX for max buffer size, the concat
    stream will follow suit.

M	src/lib/istream-concat.c

2021-09-27 20:35:19 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (a6477f0329)

    lib-storage: Add mailbox_list.disable_rebuild_on_corruption

    If set, don't try to rebuild the mailbox list index even if corruption is 
    detected.

M	src/lib-storage/list/mailbox-list-index.c
M	src/lib-storage/mailbox-list-private.h

2021-09-29 00:21:17 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (75b9572fb3)

    indexer: Abort requests if indexer-worker disconnects unexpectedly


M	src/indexer/worker-connection.c

2021-09-28 15:35:05 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (83c837b896)

    driver-pglsqlpool: Implement sql_get_flags() reliably

    Try to use one of the already connected databases. If none were found, 
    create a new database.

M	src/lib-sql/driver-sqlpool.c

2021-09-28 15:32:56 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (55b9e35361)

    driver-pgsql: Implement sql_get_flags() reliably

    Some of the flags aren't known until server is connected to, so wait for the 
    connect to finish if necessary before returning the flags.

M	src/lib-sql/driver-pgsql.c

2021-09-28 15:33:47 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (b6aa90594b)

    driver-sqlpool: Implement sql_wait()


M	src/lib-sql/driver-sqlpool.c

2021-09-27 11:59:09 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (c9ec34ed3f)

    driver-cassandra: Add wait() implementation


M	src/lib-sql/driver-cassandra.c

2021-09-27 11:58:21 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (c893eceb5f)

    driver-pgsql: Add wait() implementation


M	src/lib-sql/driver-pgsql.c

2021-09-27 11:48:34 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (6b2fcaaf10)

    dict-sql: Add "sql_dict_wait()" implementation

    lib-sql now has sql_wait().

M	src/lib-dict-backend/dict-sql.c

2021-09-27 11:46:07 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (5a04189c76)

    lib-sql: Add "wait" vfunc

    To be used in backends that support async operations. On deinit dicts should
    wait for results and then exit.

M	src/lib-sql/sql-api-private.h
M	src/lib-sql/sql-api.c
M	src/lib-sql/sql-api.h

2021-09-27 19:43:54 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (2b0ef4bb5f)

    driver-pgsql: Keep a list of pending query results

    To be used in wait() to determine if there are pending operations.

M	src/lib-sql/driver-pgsql.c

2021-09-22 20:57:06 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (eb3da845e7)

    dict: Wait for all dicts to finish pending operations at shutdown

    This also changes the dict process to exit cleanly instead of early via 
    lib_exit().

M	src/dict/dict-init-cache.c
M	src/dict/dict-init-cache.h
M	src/dict/main.c

2019-07-11 12:05:37 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (3cf237588b)

    dict: Unref dict connection immediately when connection is destroyed

    The delayed unrefing is needed when calling from dict command callbacks to 
    avoid calling dict_deinit() too early. But the connection's destroy() vfunc 
    can't be called directly from dict command callbacks, so there's no need to
    add further delays. Especially when this happens at deinit where there is no
    possibility of calling the delayed callback anymore.

M	src/dict/dict-connection.c

2021-09-27 11:42:07 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (bbac0ca054)

    driver-pgsql: Fix escaped blob prefix

    Escaped strings must be prefixed with double backslash.

M	src/lib-sql/driver-pgsql.c

2021-09-27 11:35:38 +0100 Siavash Tavakoli <siavash.tavakoli@open-xchange.com> (3c51f03bfb)

    driver-pgsql: Fix assert-crash when using binary fields

    array_idx_modifiable() changed behavior in 
    1d4e5de8414ed93d1c810b30a91ad83d6d954861 and doesn't allocate space anymore.

    Fixes: Panic: file array.c: line 10 (array_idx_modifiable_i): assertion
    failed: (idx < array->buffer->used / array->element_size)

M	src/lib-sql/driver-pgsql.c

2021-09-28 15:35:21 +0300 sergey.kitov <sergey.kitov@open-xchange.com> (f6d0765022)

    stats: Use duplicated metric settings in stats_metrics_add_dynamic().


M	src/stats/stats-metrics.c

2021-09-28 12:41:14 +0300 Aki Tuomi <aki.tuomi@open-xchange.com> (2bc7c10b23)

    configure: Set version to 2.3.17


M	configure.ac

2021-09-15 14:44:42 +0200 Markus Valentin <markus.valentin@open-xchange.com> (b04cb5ea03)

    imapc: Add MAIL_STORAGE_CLASS_FLAG_SECONDARY_INDEX storage class flag

    Add SECONDARY_INDEX storage class flag to enable storing shared private 
    indexes in obox user root bundle.

M	src/lib-storage/index/imapc/imapc-storage.c

2021-09-24 17:33:38 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (e399436c15)

    lib-storage: mail_get_binary_stream() - Add comment about having to unref
    returned istream


M	src/lib-storage/mail-storage.h

2021-09-22 15:58:55 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (1ce928c75f)

    lib: test-cpu-limit - Remove dead code

    No longer needed after 6d902507c24fca4f64e3e9bf7d79ae5a48281cd8

M	src/lib/test-cpu-limit.c

2021-09-27 11:49:05 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (0a70b02bbb)

    lib: test-strfuncs - Avoid testing p_strndup() with overlong max_chars
    parameter

    This ended up in memchr() call with n=SIZE_MAX-1, which sometimes doesn't 
    work right with old glibc versions.

    Fixes: Panic: Trying to allocate 18446744073709551615 bytes

M	src/lib/test-strfuncs.c

2021-09-08 10:39:36 +0300 Aki Tuomi <aki.tuomi@open-xchange.com> (211040d836)

    lib-mail: Add test for empty header value


M	src/lib-mail/test-message-header-parser.c

2021-09-02 17:10:11 +0300 Aki Tuomi <aki.tuomi@open-xchange.com> (d0e0b22b6b)

    lib-mail: Limit header length to 1000 bytes


M	src/lib-mail/message-header-parser.c
M	src/lib-mail/test-message-header-parser.c

2021-09-02 17:12:55 +0300 Aki Tuomi <aki.tuomi@open-xchange.com> (44c43133a4)

    lib-mail: If message header has no colon, store it as value only

    If the header is missing :, it is not valid header. Storing it as value only
    ensures it will be kept by mbox rewrite, but will not be processed as a
    header.

M	src/lib-mail/message-header-parser.c
M	src/lib-mail/test-message-header-parser.c
M	src/plugins/pop3-migration/pop3-migration-plugin.c

2021-09-02 16:46:19 +0300 Aki Tuomi <aki.tuomi@open-xchange.com> (ac65213384)

    lib-mail: test-message-header-parser - Add NAME10, 100, 1000 macros for
    testing


M	src/lib-mail/test-message-header-parser.c

2021-09-07 14:37:34 +0300 Aki Tuomi <aki.tuomi@open-xchange.com> (0009fd1edf)

    lib: Add i_memspn() and i_memcspn()

    Binary data safe variants of strspn() and strcspn()

M	src/lib/strfuncs.c
M	src/lib/strfuncs.h
M	src/lib/test-strfuncs.c

2021-09-16 13:32:37 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (8af2bd8640)

    virtual: Log a debug message why backend mailbox has changed


M	src/plugins/virtual/virtual-sync.c

2021-09-24 10:39:43 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (801405d49f)

    lib-storage: mail-duplicate - Restructure mail_duplicate_read_db_file() to
    make sure fd is closed.

    Found by Coverity.

M	src/lib-storage/mail-duplicate.c

2021-09-24 10:22:28 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (99d129cd50)

    lib-storage: mail-duplicate - Fix segfault occurring upon failure to lock
    and open DB file.

    Found by Coverity.

M	src/lib-storage/mail-duplicate.c

2021-08-18 16:54:00 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (26284cf6f7)

    indexer-worker: Fix event leak on error handling


M	src/indexer/master-connection.c

2021-07-13 04:15:14 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (2d32ee8b54)

    lib-storage: mail-duplicate - Implement separate error code for deadlock.


M	src/lib-storage/mail-duplicate.c
M	src/lib-storage/mail-duplicate.h

2021-09-16 01:49:57 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (dcee43b54c)

    lib-storage: mail-duplicate - Update records from duplicate DB file after
    acquirement of per-ID lock.

    The process previously holding the per-ID lock may have updated the DB.

M	src/lib-storage/mail-duplicate.c

2021-09-17 11:11:21 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (a27a97f49d)

    lib-storage: mail-duplicate - Move acquirement of dotlock for DB file into
    mail_duplicate_read().


M	src/lib-storage/mail-duplicate.c

2021-09-20 11:58:12 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (9cb56c3b28)

    lib-storage: mail-duplicate - Implement per-ID locking.


M	src/lib-storage/mail-duplicate.c
M	src/lib-storage/mail-duplicate.h

2021-09-17 11:16:39 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (9bd8fff3b0)

    lib-storage: mail-duplicate - Allow calling mail_duplicate_read() more than
    once in a transaction.


M	src/lib-storage/mail-duplicate.c

2021-07-13 23:22:52 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (b3d183d81d)

    lib-storage: mail-duplicate - Record an entry for both checked and marked
    IDs.

    Still only write the marked IDs to the file. The in-memory record is needed
    for the locking introduced in a later commit.

M	src/lib-storage/mail-duplicate.c

2021-07-13 05:03:02 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (711f05f3d1)

    lib-storage: mail-duplicate - Add debug messages for transaction.


M	src/lib-storage/mail-duplicate.c

2021-07-13 05:07:39 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (4809e7e1cd)

    lib-storage: mail-duplicate - Add debug messages for database.


M	src/lib-storage/mail-duplicate.c

2021-07-13 04:40:24 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (70af5522c6)

    lib-storage: mail-duplicate - Add event to transaction object.


M	src/lib-storage/mail-duplicate.c

2021-07-13 04:53:11 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (4fe7f887a6)

    lib-storage: mail-duplicate - Add event to database object.


M	src/lib-storage/mail-duplicate.c

2021-06-08 03:51:10 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (63553ff976)

    lib-storage: mail-duplicate - Restructure API to make it transaction-based.


M	src/lib-storage/mail-duplicate.c
M	src/lib-storage/mail-duplicate.h

2021-07-13 04:03:42 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (f786488b23)

    lib-storage: mail-duplicate - Change mail_duplicate_check() return type from
    bool to enum.


M	src/lib-storage/mail-duplicate.c
M	src/lib-storage/mail-duplicate.h

2021-09-17 11:04:55 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (90400db2d6)

    lib-storage: Reformat mail-duplicate.c.


M	src/lib-storage/mail-duplicate.c

2021-08-07 15:43:35 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (8bfdede141)

    lib-storage: mail-user - Add mail_user_get_volatile_dir().


M	src/lib-storage/mail-user.c
M	src/lib-storage/mail-user.h

2021-09-20 02:45:23 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (4c1cf82d61)

    lib: file-lock - Adjust API to allow EDEADLK to be used by application.

    It always caused a Dovecot panic before when returned from kernel.

M	src/lib/file-lock.c
M	src/lib/file-lock.h

2021-09-19 13:09:29 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (083439ed73)

    lib: file-lock - Rework API to make it extensible.


M	src/doveadm/dsync/dsync-brain.c
M	src/lib-dict/dict-file.c
M	src/lib-fs/fs-posix.c
M	src/lib-index/mail-index-lock.c
M	src/lib-index/mail-index-strmap.c
M	src/lib-storage/index/dbox-common/dbox-file.c
M	src/lib-storage/mail-storage.c
M	src/lib-storage/mail-user.c
M	src/lib-storage/mailbox-list.c
M	src/lib/file-create-locked.c
M	src/lib/file-create-locked.h
M	src/lib/file-lock.c
M	src/lib/file-lock.h
M	src/lib/test-file-create-locked.c
M	src/plugins/fts-squat/squat-trie.c
M	src/plugins/fts-squat/squat-uidlist.c

2021-09-20 02:39:08 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (de5e12a160)

    lib: file-lock - Rename file_{wait,try}_lock_error() to
    file_{wait,try}_lock().


M	src/lib-dict/dict-file.c
M	src/lib-fs/fs-posix.c
M	src/lib-index/mail-index-lock.c
M	src/lib-index/mail-index-strmap.c
M	src/lib-storage/index/dbox-common/dbox-file.c
M	src/lib/file-create-locked.c
M	src/lib/file-lock.c
M	src/lib/file-lock.h
M	src/plugins/fts-squat/squat-trie.c
M	src/plugins/fts-squat/squat-uidlist.c

2021-09-20 02:29:55 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (13b9181e32)

    lib: file-lock - Remove file_{wait,try}_lock().


M	src/lib/file-lock.c
M	src/lib/file-lock.h

2021-09-20 02:26:46 +0200 Stephan Bosch <stephan.bosch@open-xchange.com> (4dbae0e6c1)

    global: Avoid use of file_{wait,try}_lock().

    Use the file_{wait,try}_lock_error() variants instead.

M	src/lib-dict/dict-file.c
M	src/lib-fs/fs-posix.c
M	src/lib-index/mail-index-lock.c
M	src/lib-index/mail-index-strmap.c
M	src/lib-storage/index/dbox-common/dbox-file.c
M	src/plugins/fts-squat/squat-trie.c
M	src/plugins/fts-squat/squat-uidlist.c

2021-09-22 17:36:27 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (ed1264368a)

    lib-http: test-http-client-errors - Allow more relaxed timeouts for connect
    retry tests

    With max_connect_attempts=3 the connects come at (0ms, 100ms, 300ms). Before
    the 3rd attempt a timeout at 250ms must have triggered, so there was only
    50ms time for it to trigger. This wasn't always enough when running with
    valgrind on an overloaded system. Solve this by increasing 
    max_connect_attempts=4 so the 4th attempt comes at 700ms, giving the timeout
    450ms to trigger.

M	src/lib-http/test-http-client-errors.c

2021-09-22 12:14:08 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (4f605823a4)

    lib: Add most data_stack_grow event fields before checking if event is
    wanted

    This allows using e.g. "event=data_stack_grow and alloc_size > 32768" as an
    event filter.

M	src/lib/data-stack.c

2021-09-21 18:27:29 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (18e1eaf61e)

    config: Add data stack frame


M	src/config/config-request.c

2021-09-21 18:26:53 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (9055758361)

    doveconf: Avoid unnecessary data stack use when writing output


M	src/config/doveconf.c

2021-09-21 18:21:54 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (dab478e5f4)

    master: Create each service in its own data stack frame


M	src/master/service.c

2021-09-21 17:52:15 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (e873c9aeae)

    doveadm: Call each run() in its own data stack frame


M	src/doveadm/doveadm-mail.c

2021-09-21 17:14:44 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (7ac69350e3)

    dsync: Add data stack frames to mailbox loops


M	src/doveadm/dsync/dsync-brain-mailbox-tree.c

2021-09-21 17:10:56 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (1b4f8cf6a2)

    dsync: Split off dsync_brain_recv_mailbox_tree_add()


M	src/doveadm/dsync/dsync-brain-mailbox-tree.c

2021-09-21 17:50:32 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (d83e4f5fd2)

    acl: Code cleanup - Remove pointless while-loop


M	src/plugins/acl/acl-shared-storage.c

2021-09-21 17:03:45 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (f78c00f1f3)

    acl: acllist rebuild - Move data stack frame to caller's loop


M	src/plugins/acl/acl-backend-vfile-acllist.c

2021-09-21 16:14:12 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (e05b6df33a)

    acl: Add data stack frame when iterating mailboxes

    Avoids wasting memory when there are a lot of mailboxes.

M	src/plugins/acl/acl-mailbox-list.c

2021-09-21 17:51:15 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (5694b04f70)

    lib-storage: mail_user_unref() - Add data stack frame

    The deinit code paths can sometimes eat up quite a lot of data stack.

M	src/lib-storage/mail-user.c

2021-09-22 12:49:46 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (ef84b4e2f6)

    lib-storage: mailbox_create() - Add data stack frames


M	src/lib-storage/mail-storage.c

2021-09-22 12:48:18 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (0b1dff0b1d)

    lib-storage: Add data stack frames to [service] user initialization

    Initialization steps can use a lot of data stack, so try to free it at 
    several checkpoints.

M	src/lib-storage/mail-storage-service.c

2021-09-21 17:49:34 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (1682263f04)

    lib-storage: Add data stack frame when iterating mailboxes to build GUID
    cache


M	src/lib-storage/mailbox-guid-cache.c

2021-09-21 17:48:33 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (8c56e2c025)

    lib-storage: mailbox_verify_*name() - Add data stack frames

    This function can eat up quite a lot of data stack.

M	src/lib-storage/mail-storage.c

2021-09-21 17:47:41 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (4908b7c139)

    lib-storage: str_contains_special_use() - Add data stack frame

    This function is called in a loop by namespace_find_special_use().

M	src/lib-storage/mail-storage.c

2021-09-21 16:58:13 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (e22519d85d)

    lib-storage: List index rebuild - Add data stack frames


M	src/lib-storage/list/mail-storage-list-index-rebuild.c

2021-09-21 16:57:13 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (99b9890db0)

    lib-storage: List index rebuild - Split off
    mail_storage_list_index_find_indexed_mailbox()


M	src/lib-storage/list/mail-storage-list-index-rebuild.c

2021-09-21 16:37:13 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (8b7438a3f9)

    lib-storage: Don't use data stack for mailbox list index header update

    There can be a lot of mailboxes, causing excessive data stack usage.

M	src/lib-storage/list/mailbox-list-index-sync.c

2021-09-21 16:42:39 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (bb75bc110f)

    lib-index: Don't use data stack for building index header update buffer

    The header update can be large (e.g. dovecot.list.index with many mailboxes)
    and grow data stack unnecessarily.

M	src/lib-index/mail-index-transaction-export.c

2021-09-21 17:51:50 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (742053d520)

    lib: module_dir_deinit() - Call each deinit() in its own data stack frame


M	src/lib/module-dir.c

2021-09-21 16:15:54 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (f13526d432)

    lib: test-data-stack - Make sure data stack memory usage doesn't leak


M	src/lib/test-data-stack.c

2021-09-21 13:38:27 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (6d902507c2)

    lib: test-cpu-limit - Remove checking for CPU usage upper limit

    These tests keep randomly failing on loaded systems. It's more important 
    anyway to check that the minimum CPU usage is high enough than it is to 
    check that CPU usage isn't too high.

M	src/lib/test-cpu-limit.c

2021-09-17 16:11:12 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (ba465f3a04)

    lib: Optimize str_tabescape()


M	src/lib/strescape.c

2021-09-17 16:10:12 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (bcfc14fae3)

    lib: Optimize p_strsplit_tabescaped()


M	src/lib/strescape.c

2021-09-17 16:06:17 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (5615fa62db)

    lib: Optimize t_strsplit_tabescaped()


M	src/lib/strescape.c

2021-09-17 16:04:00 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (09b2f400d2)

    lib: Optimize t_strsplit_tabescaped_inplace()


M	src/lib/strescape.c

2021-09-17 16:02:10 +0300 Timo Sirainen <timo.sirainen@open-xchange.com> (a6b1c0114c)

    lib: Optimize t_strdup*()

    Avoid zeroing the allocated data stack memory just before it's going to be 
    filled with the duplicated string anyway.

M	src/lib/strfuncs.c

2021-03-12 01:41:35 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (6345e8f021)

    lib: Optimize t_str_tabunescape()


M	src/lib/strescape.c

2021-03-12 01:38:13 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (cd63b1eeea)

    lib: Optimize str_tabunescape()


M	src/lib/strescape.c

2021-03-12 01:27:30 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (ea636c55e4)

    lib: Optimize str_append_tabescaped()

    Avoid calling strlen() and replace for-loop with strcspn().

M	src/lib/strescape.c

2021-03-12 01:23:04 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (1abeccbeca)

    lib: Optimize str_append_tabescaped_n()


M	src/lib/strescape.c
M	src/lib/test-strescape.c

2021-03-12 01:19:38 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (de0871dedb)

    lib: Optimize p_strndup()


M	src/lib/strfuncs.c
M	src/lib/test-lib.inc
M	src/lib/test-strfuncs.c

2021-02-11 02:56:11 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (7371c1033e)

    lib: Optimize buffer_append() and buffer_append_c()


M	src/lib/buffer.c

2021-02-11 02:44:34 +0200 Timo Sirainen <timo.sirainen@open-xchange.com> (34d72ca7f2)

    lib: buffer_create_dynamic_max() - Fix max_size handling

    Never allocate buffer larger than its max_size, since it's just wasted 
    memory. Also clarify that the allocation can actually go up to max_size+1 
    because of str_c() NUL byte reservation.

M	src/lib/buffer.c
