FS#65080 - [telegram-desktop] 1.9.3-1 crashes on startup: Address boundary error

Attached to Project: Community Packages
Opened by Jan Žegklitz (zegkljan) - Wednesday, 08 January 2020, 07:36 GMT
Last edited by Jiachen Yang (farseerfc) - Saturday, 25 January 2020, 09:45 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Sven-Hendrik Haase (Svenstaro)
Jiachen Yang (farseerfc)
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 9
Private No

Details

Description:

Since version 1.9.3-1, telegram-desktop crashes on startup with Address boundary error:

$ telegram-desktop

(telegram-desktop:12417): GLib-GObject-WARNING **: 08:22:03.129: cannot register existing type 'GdkDisplayManager'

(telegram-desktop:12417): GLib-CRITICAL **: 08:22:03.129: g_once_init_leave: assertion 'result != 0' failed

(telegram-desktop:12417): GLib-GObject-CRITICAL **: 08:22:03.129: g_object_new_with_properties: assertion 'G_TYPE_IS_OBJECT (object_type)' failed

(telegram-desktop:12417): GLib-GObject-WARNING **: 08:22:03.129: invalid (NULL) pointer instance

(telegram-desktop:12417): GLib-GObject-CRITICAL **: 08:22:03.129: g_signal_connect_data: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed

(telegram-desktop:12417): GLib-GObject-WARNING **: 08:22:03.129: invalid (NULL) pointer instance

(telegram-desktop:12417): GLib-GObject-CRITICAL **: 08:22:03.129: g_signal_connect_data: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed

(telegram-desktop:12417): GLib-GObject-WARNING **: 08:22:03.129: cannot register existing type 'GdkDisplay'

(telegram-desktop:12417): GLib-CRITICAL **: 08:22:03.129: g_once_init_leave: assertion 'result != 0' failed

(telegram-desktop:12417): GLib-GObject-CRITICAL **: 08:22:03.129: g_type_register_static: assertion 'parent_type > 0' failed

(telegram-desktop:12417): GLib-CRITICAL **: 08:22:03.129: g_once_init_leave: assertion 'result != 0' failed

(telegram-desktop:12417): GLib-GObject-CRITICAL **: 08:22:03.129: g_object_new_with_properties: assertion 'G_TYPE_IS_OBJECT (object_type)' failed
fish: “telegram-desktop” terminated by signal SIGSEGV (Address boundary error)



Previous version (1.8.15-4) worked flawlessly:

$ sudo pacman -U /var/cache/pacman/pkg/telegram-desktop-1.8.15-4-x86_64.pkg.tar.xz
...
warning: downgrading package telegram-desktop (1.9.3-1 => 1.8.15-4)
...
$ telegram-desktop
QApplication: invalid style override passed, ignoring it.
Available styles: Windows, Fusion
(and the application works fine)



Also, the AUR package telegram-desktop-bin (https://aur.archlinux.org/packages/telegram-desktop-bin) of the same version (1.9.3-1) works without any problems.
This task depends upon

Closed by  Jiachen Yang (farseerfc)
Saturday, 25 January 2020, 09:45 GMT
Reason for closing:  Fixed
Additional comments about closing:  fixed since 1.9.4-2
Comment by edac val (edacval) - Wednesday, 08 January 2020, 17:22 GMT
Same error. Also coredump log from journald:

Jan 08 19:10:05 amd systemd[1]: systemd-coredump@3-26624-0.service: Succeeded.
Jan 08 19:10:05 amd systemd-coredump[26625]: Process 26618 (telegram-deskto) of user 1000 dumped core.

Stack trace of thread 26618:
#0 0x00007f2634e61342 gdk_display_open (libgdk-x11-2.0.so.0 + 0x4d342)
#1 0x00007f2634e30052 gdk_display_open_default_libgtk_only (libgdk-x11-2.0.so.0 + 0x1c052)
#2 0x00007f26351f3c53 gtk_init_check (libgtk-x11-2.0.so.0 + 0x12bc53)
#3 0x000055586c337536 n/a (telegram-desktop + 0x14be536)
#4 0x000055586c338008 n/a (telegram-desktop + 0x14bf008)
#5 0x000055586c3541ca n/a (telegram-desktop + 0x14db1ca)
#6 0x000055586bc0b90d n/a (telegram-desktop + 0xd9290d)
#7 0x000055586bba2a0d n/a (telegram-desktop + 0xd29a0d)
#8 0x000055586bbdd77a n/a (telegram-desktop + 0xd6477a)
#9 0x000055586bbdd88f n/a (telegram-desktop + 0xd6488f)
#10 0x00007f2646040832 _ZN16QCoreApplication15notifyInternal2EP7QObjectP6QEvent (libQt5Core.so.5 + 0x2a4832)
#11 0x00007f2646043096 _ZN23QCoreApplicationPrivate16sendPostedEventsEP7QObjectiP11QThreadData (libQt5Core.so.5 + 0x2a7096)
#12 0x00007f2646099674 n/a (libQt5Core.so.5 + 0x2fd674)
#13 0x00007f264115e39e g_main_context_dispatch (libglib-2.0.so.0 + 0x6a39e)
#14 0x00007f26411601b1 n/a (libglib-2.0.so.0 + 0x6c1b1)
#15 0x00007f26411601f1 g_main_context_iteration (libglib-2.0.so.0 + 0x6c1f1)
#16 0x00007f2646098cc0 _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Core.so.5 + 0x2fccc0)
#17 0x00007f264603f39c _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5 + 0x2a339c)
#18 0x00007f26460473a6 _ZN16QCoreApplication4execEv (libQt5Core.so.5 + 0x2ab3a6)
#19 0x000055586bbdc192 n/a (telegram-desktop + 0xd63192)
#20 0x000055586bbcc14f n/a (telegram-desktop + 0xd5314f)
#21 0x000055586bbcc25d n/a (telegram-desktop + 0xd5325d)
#22 0x000055586b26fc8a n/a (telegram-desktop + 0x3f6c8a)
#23 0x00007f26452cf153 __libc_start_main (libc.so.6 + 0x27153)
#24 0x000055586b27055e n/a (telegram-desktop + 0x3f755e)

Stack trace of thread 26621:
#0 0x00007f264539c9ef __poll (libc.so.6 + 0xf49ef)
#1 0x00007f2641160120 n/a (libglib-2.0.so.0 + 0x6c120)
#2 0x00007f26411610c3 g_main_loop_run (libglib-2.0.so.0 + 0x6d0c3)
#3 0x00007f263caecbc8 n/a (libgio-2.0.so.0 + 0x59bc8)
#4 0x00007f264113cbb1 n/a (libglib-2.0.so.0 + 0x48bb1)
#5 0x00007f2645c3e4cf start_thread (libpthread.so.0 + 0x94cf)
#6 0x00007f26453a72d3 __clone (libc.so.6 + 0xff2d3)

Stack trace of thread 26620:
#0 0x00007f264539c9ef __poll (libc.so.6 + 0xf49ef)
#1 0x00007f2641160120 n/a (libglib-2.0.so.0 + 0x6c120)
#2 0x00007f26411601f1 g_main_context_iteration (libglib-2.0.so.0 + 0x6c1f1)
#3 0x00007f2641160242 n/a (libglib-2.0.so.0 + 0x6c242)
#4 0x00007f264113cbb1 n/a (libglib-2.0.so.0 + 0x48bb1)
#5 0x00007f2645c3e4cf start_thread (libpthread.so.0 + 0x94cf)
#6 0x00007f26453a72d3 __clone (libc.so.6 + 0xff2d3)

Stack trace of thread 26623:
#0 0x00007f264539c9ef __poll (libc.so.6 + 0xf49ef)
#1 0x00007f2641160120 n/a (libglib-2.0.so.0 + 0x6c120)
#2 0x00007f26411601f1 g_main_context_iteration (libglib-2.0.so.0 + 0x6c1f1)
#3 0x00007f2646098cc0 _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Core.so.5 + 0x2fccc0)
#4 0x00007f264603f39c _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5 + 0x2a339c)
#5 0x00007f2645e64e62 _ZN7QThread4execEv (libQt5Core.so.5 + 0xc8e62)
#6 0x00007f26471eeb28 n/a (libQt5DBus.so.5 + 0x15b28)
#7 0x00007f2645e65fd6 n/a (libQt5Core.so.5 + 0xc9fd6)
#8 0x00007f2645c3e4cf start_thread (libpthread.so.0 + 0x94cf)
#9 0x00007f26453a72d3 __clone (libc.so.6 + 0xff2d3)

Stack trace of thread 26619:
#0 0x00007f264539c9ef __poll (libc.so.6 + 0xf49ef)
#1 0x00007f26410d6630 n/a (libxcb.so.1 + 0xc630)
#2 0x00007f26410d82db xcb_wait_for_event (libxcb.so.1 + 0xe2db)
#3 0x00007f263e8a4a01 n/a (libQt5XcbQpa.so.5 + 0x65a01)
#4 0x00007f2645e65fd6 n/a (libQt5Core.so.5 + 0xc9fd6)
#5 0x00007f2645c3e4cf start_thread (libpthread.so.0 + 0x94cf)
#6 0x00007f26453a72d3 __clone (libc.so.6 + 0xff2d3)

Stack trace of thread 26622:
#0 0x00007f264539c9ef __poll (libc.so.6 + 0xf49ef)
#1 0x00007f2641160120 n/a (libglib-2.0.so.0 + 0x6c120)
#2 0x00007f26411601f1 g_main_context_iteration (libglib-2.0.so.0 + 0x6c1f1)
#3 0x00007f2646098cc0 _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Core.so.5 + 0x2fccc0)
#4 0x00007f264603f39c _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5 + 0x2a339c)
#5 0x00007f2645e64e62 _ZN7QThread4execEv (libQt5Core.so.5 + 0xc8e62)
#6 0x00007f2645e65fd6 n/a (libQt5Core.so.5 + 0xc9fd6)
#7 0x00007f2645c3e4cf start_thread (libpthread.so.0 + 0x94cf)
#8 0x00007f26453a72d3 __clone (libc.so.6 + 0xff2d3)
Jan 08 19:10:04 amd systemd[1]: Started Process Core Dump (PID 26624/UID 0).
Jan 08 19:10:04 amd kernel: Code: 48 89 c3 4c 8d 64 24 40 67 e8 aa fe ff ff 31 f6 48 89 c7 31 c0 ff 15 35 50 26 00 49 89 c5 31 d2 48 8d 35 e1 fd ff ff 48 89 df <c7> 80 14 01 00 00 01 00 00 00 48 89 98 d8 00 00 00 ff 15 8f 52 26
Jan 08 19:10:04 amd kernel: telegram-deskto[26618]: segfault at 114 ip 00007f2634e61342 sp 00007ffc06ba55e0 error 6 in libgdk-x11-2.0.so.0.2400.32[7f2634e14000+ae000]



Comment by edac val (edacval) - Thursday, 09 January 2020, 03:03 GMT
Fixed by installing libappindicator-gtk3 . libappindicator-gtk3 should be moved from optdepends() to depends().
Comment by Javier Fernández (WyRe) - Thursday, 09 January 2020, 15:50 GMT
Thank you for the info, @edacval I was experiencing the same problem. However ... in my case (I'm using i3+polybar) the system tray icon is not shown.

I got that terminal output when I start `telegram-desktop` from there:

(telegram-desktop:6762): libappindicator-CRITICAL **: 16:51:30.195: app_indicator_set_icon_full: assertion 'IS_APP_INDICATOR (self)' failed
OpenType support missing for "Open Sans Semibold", script 15
OpenType support missing for "Open Sans", script 15
OpenType support missing for "Open Sans Semibold", script 14
OpenType support missing for "Open Sans", script 14
Comment by edac val (edacval) - Thursday, 09 January 2020, 17:03 GMT
@WyRe try to install ttf-opensans, should solve warnings about missing fonts at least
Comment by Javier Fernández (WyRe) - Thursday, 09 January 2020, 17:05 GMT
@edecval I've got it already.
Comment by David Parrish (dmp1ce) - Saturday, 11 January 2020, 13:43 GMT
Installing libappindicator-gtk3 fixes issue for me too.
Comment by Jiachen Yang (farseerfc) - Wednesday, 22 January 2020, 03:51 GMT
telegram-desktop 1.9.4-2 (now in community-testing) make libappindicator-gtk3 as a hard dependency.
Can someone please test whether this release fixed the problem and don't have other side effects?
Comment by edac val (edacval) - Wednesday, 22 January 2020, 05:15 GMT
tested 1.9.4-1, works with libappindicator-gtk3, without libappindicator-gtk3 crashes immediately on start.
Same result on 1.9.4-2 from community-testing. LXDE
Comment by vasya (vasya) - Wednesday, 22 January 2020, 15:45 GMT
Also confirming without `libappindicator-gtk3` telegram-desktop crashes on start, but with `libappindicator-gtk3` installed it runs smoothly.
Comment by Michael (bloor) - Thursday, 23 January 2020, 15:09 GMT
What WMs / DEs are you guys all running?

I manage run `telegram-desktop=1.9.4-1` perfectly without `libappindicator-gtk3` installed.
Using `sway` (a wayland wm) with `waybar`, have `qt5-wayland` installed and QT wayland support enabled, but I tested and it also works running on Xwayland.
The inidicator icon in waybar is visible and clickable, notifications work both via the Telegram-internal system and `mako`.

However, what I do have installed is `libdbusmenu-gtk3`, a dependency for both `libappindicator-gtk3` and `waybar`, but even after removing `libdbusmenu-gtk3`, `libdbusmenu-glib` and `libdbusmenu-qt5` Telegram still opens fine.
I refrained from uninstalling gtk3 and glib2 themselves, because they are fairly implicit base packages.

After short testing I can't figure out, what the problem is, it may very well be a missing dependency, but `libappindicator-gtk3` doesn't seem to be really needed.
Comment by edac val (edacval) - Thursday, 23 January 2020, 15:36 GMT Comment by Michael (bloor) - Thursday, 23 January 2020, 16:40 GMT
@edacval Thank you, after installing `qt5-styleplugins` and forcefully setting the gtk2 theme with `QT_STYLE_OVERRIDE=gtk2` (the variable QT_QPA_PLATFORMTHEME=gtk2 as suggested by the Wiki did not cause the crash and worked for other applications) I was able to reproduce the crash.

Still IMO the best solution to this problem is not to force an "unneeded" hard-dependency, but rather encourage people to properly configure their systems.^^

EDIT: I just found out the QT_QPA_PLATFORMTHEME env var is unset before launching telegram, maybe doing the same with the QT_STYLE_OVERRIDE could solve the problem?
Comment by Jiachen Yang (farseerfc) - Friday, 24 January 2020, 00:45 GMT
We now forced a hard dependency on libappindicator-gtk3 from telegram-desktop 1.9.4-2 and 1.9.7 , hope this solve the issue.
Comment by edac val (edacval) - Friday, 24 January 2020, 12:55 GMT
@farseerfc Thanks, works for me. I think this can be closed

Loading...