Todd Carson
73603c97e2
Don't declare mu_str_size_s() with the const attribute.
...
When this function is declared const or pure, clang at -O1 or higher optimizes
away the call to mu_str_size_s() inside mu_str_size(), so that it ignores its
argument and returns whatever is in mu_str_size_s()'s static buffer.
Found when test-mu-str failed while testing an update of mu in OpenBSD's ports tree.
2020-07-01 00:16:19 +09:00
Dirk-Jan C. Binnema
556b898e4d
lib: Remove unused file
2020-06-28 13:23:56 +03:00
Dirk-Jan C. Binnema
c8eff488ba
cosmetics
2020-06-27 17:07:00 +03:00
Dirk-Jan C. Binnema
4617935d80
store: Update for the new indexer
...
Update some APIs so we can use it with the new indexer.
Remove some now-obsolete C APIs.
2020-06-27 17:07:00 +03:00
Dirk-Jan C. Binnema
4e6bd7dfdf
lib/index: Implement new indexer
...
Implement a new message indexer consisting of a single-threaded scanner
and a multi-threaded indexer.
This allows for a number of optimizations as well as background
indexing, though this initial version should be behave similar to the
old indexer.
2020-06-27 17:07:00 +03:00
Dirk-Jan C. Binnema
f416ad4249
utils: Add async-queue
...
Like GAsyncQueue, but for c++
2020-06-27 17:07:00 +03:00
Dirk-Jan C. Binnema
1b056f4c51
utils: Add Mu::canonicalize_filename
...
We need it for unit-tests
2020-06-27 17:07:00 +03:00
Dirk-Jan C. Binnema
6061898c2b
utils: Clean up duration helpers
2020-06-27 17:07:00 +03:00
Dirk-Jan C. Binnema
5922cd9fa2
lib/mu-msg: benchmark message creation
2020-06-26 19:26:45 +03:00
Dirk-Jan C. Binnema
73f4c49364
utils: add async-queue, ansio-printer
...
Add an async-queue (rougly, GAsyncQueue but in c++ using a deque)
Add an ANSI color printer.
2020-06-26 19:21:04 +03:00
Dirk-Jan C. Binnema
9762b1bc3b
utils/command-parser: Make property key ":" prefix explicit
...
Avoid a bit of 'magic' so we can catch missing ':' in property :keys
easier.
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
981c781425
store: add bit more debug-logging
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
cf2e4f1dcd
lib/mu-msg: cosmetic
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
fe6582c6d6
lib: implement mu_store_update
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
a9fab4abcc
mu: convert command-line tools to c++
2020-06-13 16:56:41 +03:00
Dirk-Jan C. Binnema
6a7449c7e3
mu-msg-sexp: correctly mask date/time bits
...
Typo fix.
2020-06-10 21:50:23 +03:00
Dirk-Jan C. Binnema
2f8850ea86
utils/sexp: add a bit more convenience
2020-06-09 19:52:03 +03:00
Dirk-Jan C. Binnema
b10b243b54
lib/utils: update unit test
2020-06-07 18:11:41 +03:00
Dirk-Jan C. Binnema
452f62f5c0
lib: update msg->sexp to use programmatic s-expressions
...
Use the new mu-sexp capabilities.
2020-06-06 14:27:25 +03:00
Dirk-Jan C. Binnema
3afdc08d50
lib/utils: build s-expression programmatically building
...
Allow for programmatically buildings sexps, rather that using raw
strings.
2020-06-06 14:27:25 +03:00
Dirk-Jan C. Binnema
4dd764d9e8
lib/utils: add mu-logger.{cc,hh}
...
They were missing.
Fixes #1713 .
2020-05-30 18:33:27 +03:00
Dirk-Jan C. Binnema
3e233cba9a
rework logging system
...
reimplement the old mu-log.[ch] into mu-logging.{cc,hh}
If available (and using an appropriately equipped glib), log to the
systemd journal
Only g_criticals have stderr output, all the other g_* go to the log
file / journal.
2020-05-30 13:29:44 +03:00
Dirk-Jan C. Binnema
0a49cead33
build: don't require glib 2.58 for g_canonicalize_file
...
GLib version is probably still a bit too new, so simply lift the
function needed.
Fixes : #1712 .
2020-05-28 00:37:29 +03:00
Dirk-Jan C. Binnema
8bfcb7430b
lib/mu-msg-file: Use canonical path instead of real path
...
For the new symlink-support, it's better to use the *canonical* path than
the *realpath(3)* for files, so removing a symlinked maildir will work as
expected.
2020-05-27 18:55:18 +03:00
Dirk-Jan C. Binnema
fdac81e023
lib: follow symlinks in maildirs
...
Until now, mu would _not_ follow symlinks; with these changes, we do.
There were some complications with that ~10 years ago, but I forgot the
details. So let's re-enable. At least one thing is in place now: moving
between file systems.
Fixes #1489
Fixes #1628 (technically, this came with slightly earlier commit)
2020-05-26 19:22:41 +03:00
Dirk-Jan C. Binnema
015fae7b1a
guile: fix readline linking
...
For now, simply link muguile against readline; hopefully, we can make
this transitive.
2020-05-26 00:41:46 +03:00
Dirk-Jan C. Binnema
7e49f83c9f
mu-maildir: attempt to allow moving to different fs
...
Add an EXDEV fallback for moving a file to a different filesystem.
2020-05-25 21:40:02 +03:00
Dirk-Jan C. Binnema
f67b551460
mu-maildir: avoid unnecessarily moving new-name files
...
When calling mu_maildir_move_message with the new_name
options (workaround for mbsync's), do the src=target check *without* first
creating that new name.
This avoids some unnecessary moves.
2020-05-25 21:26:00 +03:00
Dirk-Jan C. Binnema
286225be8f
Merge pull request #1705 from nickg/windows-file-sep
...
Allow ';' as a Maildir flags seperator
2020-05-25 20:52:30 +03:00
Dirk-Jan C. Binnema
b60cfc7df2
mu-server: restore readline-support
...
Restore readline support for `mu server' (but _only_ when readline is
found and when in tty mode)
2020-05-25 18:34:42 +03:00
Nick Gasson
f8fcb55f91
Allow ';' as a Maildir flags seperator
...
Isync uses this by default on Windows where ':' is an invalid character
in file names. Also try to preserve the existing separator character
when generating a new file name.
2020-05-23 09:21:57 +08:00
Dirk-Jan C. Binnema
35db0f5906
mu-contacts: cosmetic
2020-05-17 14:53:18 +03:00
Dirk-Jan C. Binnema
53b553124c
Merge pull request #1663 from czan/master
...
mu: always sort descending within threads
2020-05-17 14:45:39 +03:00
Jonas Bernoulli
564d892701
Fix typos
2020-05-12 23:56:55 +02:00
Dirk-Jan C. Binnema
f44f81b751
mu: don't verify signatures when it's not needed
...
We were verifying signatures when this was not needed; it seems that
gpgme is a bit slow (?), and on some people's machine the extra
verification made opening messages slow (with the non-gnus view esp.)
2020-05-05 21:25:36 +03:00
Kristian Rietveld
c3032bd672
mu-store: enlarge buffer for strftime
...
On Debian 9 random memory was printed with the original buffer size
and valgrind complained about the use of uninitialized memory.
2020-05-01 20:47:45 +02:00
Dirk-Jan C. Binnema
7c3673b3de
mu: do a full index when the database is empty
...
I.e., do _not_ honor .noupdate in that case.
2020-04-29 20:27:49 +03:00
Carlo Zancanaro
928dc5e0fc
mu: always sort descending within threads
2020-04-29 10:55:19 +10:00
Dirk-Jan C. Binnema
06d3deb4cc
guile: path updates for 2.2
2020-04-20 00:01:07 +03:00
Dominik Schrempf
ccbd81f6ef
~/.mu -> ~/.cache/mu
2020-04-19 13:02:48 +02:00
Dirk-Jan C. Binnema
a4fded5edd
mu: ensure some struct members are initialized
2020-03-31 21:19:03 +03:00
Dirk-Jan C. Binnema
46ae663937
mu4e: use faster count queries, document differences
...
Use faster queries for counting read/unread messages; document why the
results might differ from what you get doing a normal search.
2020-03-15 01:23:01 +02:00
Dirk-Jan C. Binnema
49883806f6
store: remove unused code, use batchsize
2020-03-02 23:19:34 +02:00
Dirk-Jan C. Binnema
a76720af42
make OP_WILDCARD non-conditional
...
Since we require Xapian 1.4 anyway, there's no need to make OP_WILDCARD
conditional.
2020-03-02 23:02:17 +02:00
damon-kwok
56b434347e
error fix for gcc 9.x
2020-02-29 20:40:22 +08:00
Dirk-Jan C. Binnema
07e4a28deb
man: remove max-msg-size from index man-page
...
We still keep in the code, as there are some future plans to handle it
there in a different way.
Fixes #1591 .
2020-02-26 19:31:24 +02:00
Dirk-Jan C. Binnema
934adae70a
lib: use same allocator when copying MuMsgPartSigStatusReport
...
Fixes a sigabrt when freeing later.
2020-02-23 15:20:01 +02:00
Dirk-Jan C. Binnema
ac164b7e26
mu-command-parser: do not allow unknown parameters
...
We were simply ignoring unknown parameters; but it's better to raise an
error, as it's likely unintented (typo or otherwise)
2020-02-22 14:11:54 +02:00
Dirk-Jan C. Binnema
650c4c052d
store: catch exceptions in dtor
2020-02-21 19:29:27 +02:00
Dirk-Jan C. Binnema
ff79d2b7d3
msg-crypto: fix small leak
2020-02-21 19:29:27 +02:00