update to use fmt-based apis

Not complete, but a first big stab converting users of Mu::Error and
various g_warning & friends, format to the new libfmt-based APIs.
This commit is contained in:
Dirk-Jan C. Binnema
2023-07-05 23:10:13 +03:00
parent 742ca33740
commit 4920b56671
46 changed files with 435 additions and 449 deletions

View File

@ -55,7 +55,7 @@ install_sig_handler(void)
for (i = 0; i != G_N_ELEMENTS(sigs); ++i)
if (sigaction(sigs[i], &action, NULL) != 0)
g_critical("set sigaction for %d failed: %s",
mu_critical("set sigaction for {} failed: {}",
sigs[i], g_strerror(errno));
}
@ -79,7 +79,7 @@ Mu::mu_cmd_index(Store& store, const Options& opts)
{
const auto mdir{store.root_maildir()};
if (G_UNLIKELY(access(mdir.c_str(), R_OK) != 0))
return Err(Error::Code::File, "'%s' is not readable: %s",
return Err(Error::Code::File, "'{}' is not readable: {}",
mdir.c_str(), g_strerror(errno));
MaybeAnsi col{!opts.nocolor};