Package: nheko
Version: 0.6.3-1
Severity: normal
Control: tags -1 + fixed-upstream
Control: tags -1 + forwarded https://github.com/Nheko-Reborn/mtxclient/issues/3

Dear Maintainer,

because mtxclient has no package in Debian and nheko static-links with
it (Bug#926668), I'm filing this against the nheko package.

The above mentioned version of the package includes an older version of
mtxclient, which does not yet include an upstream patch for preventing a
crash in nheko Reborn in Debian.

The patch to mtxclient is attached. The crash is reproduced in Matrix
room version 3, which as of today is not yet the default room version
and thus doesn't impact the usability of this package too much yet.

Please consider fixing this issue in the package available from Debian,
due to the way mtxclient is currently packaged with nheko.

-- System Information:
Debian Release: buster/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 4.19.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US:en (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages nheko depends on:
ii  libboost-atomic1.67.0     1.67.0-13
ii  libboost-chrono1.67.0     1.67.0-13
ii  libboost-date-time1.67.0  1.67.0-13
ii  libboost-iostreams1.67.0  1.67.0-13
ii  libboost-random1.67.0     1.67.0-13
ii  libboost-regex1.67.0      1.67.0-13
ii  libboost-system1.67.0     1.67.0-13
ii  libboost-thread1.67.0     1.67.0-13
ii  libc6                     2.28-8
ii  libcmark0                 0.28.3-1
ii  libgcc1                   1:8.3.0-5
ii  liblmdb0                  0.9.22-1
ii  libolm2                   2.2.2+git20170526.0fd768e+dfsg-1+b11
ii  libqt5concurrent5         5.11.3+dfsg1-1
ii  libqt5core5a              5.11.3+dfsg1-1
ii  libqt5dbus5               5.11.3+dfsg1-1
ii  libqt5gui5                5.11.3+dfsg1-1
ii  libqt5multimedia5         5.11.3-2
ii  libqt5network5            5.11.3+dfsg1-1
ii  libqt5svg5                5.11.3-2
ii  libqt5widgets5            5.11.3+dfsg1-1
ii  libsodium23               1.0.17-1
ii  libssl1.1                 1.1.1b-1
ii  libstdc++6                8.3.0-5
ii  zlib1g                    1:1.2.11.dfsg-1

Versions of packages nheko recommends:
ii  ca-certificates  20190110

nheko suggests no packages.

-- no debconf information
From 67d39691666bcdf3cc660db19ccc0d9941df13fd Mon Sep 17 00:00:00 2001
From: redsky17 <joedono...@gmail.com>
Date: Fri, 22 Feb 2019 03:24:14 +0000
Subject: [PATCH] Fix Room v3 Issue

This at least partially addresses #3.  I have a feeling that
additional updates will be needed at some point, but this
fixes the issue where mtxclient would throw an exception for
unrecognized event id formats, which caused nheko to crash.
---
 include/mtx/identifiers.hpp | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/include/mtx/identifiers.hpp b/include/mtx/identifiers.hpp
index 87acc43..7885885 100644
--- a/include/mtx/identifiers.hpp
+++ b/include/mtx/identifiers.hpp
@@ -90,7 +90,10 @@ parse(const std::string &id)
                 identifier.hostname_  = id.substr(parts + 1);
                 identifier.id_        = id;
         } else {
-                throw std::invalid_argument(id + ": invalid format\n");
+                // V3 event ids don't use ':' at all, don't parse them the same way.
+                identifier.localpart_ = id;
+                identifier.hostname_ = id;
+                identifier.id_ = id;
         }
 
         return identifier;

Reply via email to