diff options
| author | Dirk-Jan C. Binnema <djcb@djcbsoftware.nl> | 2023-04-04 23:24:18 +0300 |
|---|---|---|
| committer | Dirk-Jan C. Binnema <djcb@djcbsoftware.nl> | 2023-04-06 07:19:26 +0300 |
| commit | cd23e6015d4725f780807d8fecf718304aa58faa (patch) | |
| tree | 72965454dd5f98bd04029721d0b4b4806d33665c /mu/mu-cmd.cc | |
| parent | 6f2c934d7223fb18c9c5e077e876f76b627d58b6 (diff) | |
mu: allow relative message paths in mu commands
Diffstat (limited to 'mu/mu-cmd.cc')
| -rw-r--r-- | mu/mu-cmd.cc | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/mu/mu-cmd.cc b/mu/mu-cmd.cc index 0f4af1a..3f8a7c9 100644 --- a/mu/mu-cmd.cc +++ b/mu/mu-cmd.cc @@ -156,12 +156,7 @@ handle_msg(const std::string& fname, const Options& opts) { using Format = Options::View::Format; - // make absolute. - const auto fpath{to_string_opt_gchar(g_canonicalize_filename(fname.c_str(), NULL))}; - if (!fpath) - return Err(Error::Code::File, "invalid file '%s'", fname.c_str()); - - auto message{Message::make_from_path(*fpath, message_options(opts.view))}; + auto message{Message::make_from_path(fname, message_options(opts.view))}; if (!message) return Err(message.error()); |
