Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Frequent crashes (SEGV) in libappindicator.so.1.0.0 #30

Closed
tvannahl opened this issue May 11, 2018 · 35 comments
Closed

Frequent crashes (SEGV) in libappindicator.so.1.0.0 #30

tvannahl opened this issue May 11, 2018 · 35 comments
Labels
upstream Issues that we can't fix because they are Discord's

Comments

@tvannahl
Copy link

tvannahl commented May 11, 2018

Discord does frequently crash on my system (Fedora 28, Gnome 3.28 Desktop, Flatpak 0.11.7).

Currently I was unable to trigger the bug on purpose or filter out a specific context on which it happens. But it does happen a lot on my system:

tvn@monolith:~ $ coredumpctl info 9881
           PID: 9881 (discord)
           UID: 1000 (tvn)
           GID: 1000 (tvn)
        Signal: 11 (SEGV)
     Timestamp: Thu 2018-05-10 02:39:38 CEST (1 day 1h ago)
  Command Line: /app/extra/discord
    Executable: /newroot/app/extra/discord
 Control Group: /user.slice/user-1000.slice/user@1000.service/flatpak-com.discordapp.Discord-9854.scope
          Unit: user@1000.service
     User Unit: flatpak-com.discordapp.Discord-9854.scope
         Slice: user-1000.slice
     Owner UID: 1000 (tvn)
       Boot ID: <>
    Machine ID: <>
      Hostname: monolith
       Storage: /var/lib/systemd/coredump/core.discord.1000.<>.9881.1525912778000000.lz4
       Message: Process 9881 (discord) of user 1000 dumped core.
                
                Stack trace of thread 2:
                #0  0x00007f00dec4e00e n/a (/app/lib/libappindicator.so.1.0.0)
                #1  0x00007f00fe98f3c5 n/a (/usr/lib/libgobject-2.0.so.0.5200.3)

The full backtrace including com.discordapp.Discord.Debug does look like the following:

(gdb) bt full
#0  0x00007fe1d5d2e00e in  () at /app/lib/libappindicator.so
#1  0x00007fe1f5a6f3c5 in g_closure_invoke () at /lib/libgobject-2.0.so.0
#2  0x00007fe1f5a813d2 in  () at /lib/libgobject-2.0.so.0
#3  0x00007fe1f5a8a02c in g_signal_emit_valist () at /lib/libgobject-2.0.so.0
#4  0x00007fe1f5a8a40f in g_signal_emit () at /lib/libgobject-2.0.so.0
#5  0x00007fe1d5d2ed4f in app_indicator_set_icon_full () at /app/lib/libappindicator.so
#6  0x000000000077851a in  ()
#7  0x0000000001de7123 in  ()
#8  0x0000000001e4bd4e in  ()
#9  0x0000000001e6e34c in  ()
#10 0x0000000001e6e668 in  ()
#11 0x0000000001e6e9cb in  ()
#12 0x0000000001df971a in  ()
#13 0x00007fe1f354b1c7 in g_main_context_dispatch () at /lib/libglib-2.0.so.0
#14 0x00007fe1f354b430 in  () at /lib/libglib-2.0.so.0
#15 0x00007fe1f354b4dc in g_main_context_iteration () at /lib/libglib-2.0.so.0
#16 0x0000000001df9606 in  ()
#17 0x0000000001e6e0e7 in  ()
#18 0x0000000001e29570 in  ()
#19 0x0000000000c37ec8 in  ()
#20 0x0000000000c37d15 in  ()
#21 0x0000000000c1da7d in  ()
#22 0x0000000000a9282e in  ()
#23 0x00000000007892d4 in  ()
#24 0x00000000007896e0 in  ()
#25 0x0000000003b830a3 in main ()

For me this looks like a bug relevant for io.atom.electron.BaseApp. I tried for hours to gather more information, but I am not a C/C++ developer. Furthermore I only found out that libappindicator is quite a mess someone really should take over. The bugs did occur without having "application indicator" support active in my desktop, I will run everything with active "application indicator" on my gnome-shell but for now that is fresh — so I don't know if it does affect the bug.

@refi64
Copy link
Contributor

refi64 commented Jan 18, 2019

@tvannahl Does this still occur with the latest version?

@tvannahl
Copy link
Author

I'll try it out by deactivating the Appindicator extension for the next week.

@tvannahl
Copy link
Author

I haven't had any problems until now. It appears to be fixed, I'll reopen if the problem resurfaces.

@tvannahl
Copy link
Author

Found it - again!

           PID: 3581 (discord)
           UID: 1000 (tvn)
           GID: 1000 (tvn)
        Signal: 11 (SEGV)
     Timestamp: Wed 2019-02-13 21:54:38 CET (52s ago)
  Command Line: /app/extra/discord
    Executable: /app/extra/discord
 Control Group: /user.slice/user-1000.slice/user@1000.service/flatpak-com.discordapp.Discord-3538.scope
          Unit: user@1000.service
     User Unit: flatpak-com.discordapp.Discord-3538.scope
         Slice: user-1000.slice
     Owner UID: 1000 (tvn)
       Boot ID: 6aef1437004444748a9105074f9d466a
    Machine ID: 1ca312ca79964d55a8595ec375a82c96
      Hostname: monolith
       Storage: /var/lib/systemd/coredump/core.discord.1000.6aef1437004444748a9105074f9d466a.3581.1550091278000000.lz4
       Message: Process 3581 (discord) of user 1000 dumped core.
                
                Stack trace of thread 4:
                #0  0x00007f9d7dd492b5 n/a (/app/lib/libappindicator3.so.1.0.0)

@tvannahl tvannahl reopened this Feb 13, 2019
@JonasKnarbakk
Copy link

Happening to me as well.

feb. 18 19:50:36 manjaro-host budgie-panel.desktop[1353]: [Modules] Checking for host updates.
feb. 18 19:50:36 manjaro-host budgie-panel.desktop[1353]: [Modules] Host is up to date.
feb. 18 19:50:36 manjaro-host budgie-panel.desktop[1353]: [Modules] Checking for module updates at https://discordapp.com/api/modules/stable/versions.json
feb. 18 19:50:36 manjaro-host budgie-panel.desktop[1353]: [Modules] No module updates available.
feb. 18 19:50:38 manjaro-host audit[11080]: ANOM_ABEND auid=1000 uid=1000 gid=1000 ses=2 pid=11080 comm="discord" exe="/app/extra/discord" sig=11 res=1
feb. 18 19:50:38 manjaro-host kernel: discord[11080]: segfault at 1e63943ad000 ip 00007fc70d3142b5 sp 00007ffe28c46d40 error 4 in libappindicator3.so.1.0.0[7fc70d310000+6000]
feb. 18 19:50:38 manjaro-host kernel: Code: ff 49 89 c5 48 8b 45 18 48 83 78 28 00 74 4d 48 8d 54 24 0c 48 8d 74 24 10 4c 89 ef 31 db e8 82 c0 ff ff 66 90 48 8b 44 24 10 <48> 8b 3c d8 39 5c 24 0c 7f 09 48 85 ff 0f 85 48 01 00 00 48 8b 45
feb. 18 19:50:38 manjaro-host kernel: audit: type=1701 audit(1550515838.777:91): auid=1000 uid=1000 gid=1000 ses=2 pid=11080 comm="discord" exe="/app/extra/discord" sig=11 res=1
feb. 18 19:50:38 manjaro-host systemd[1]: Started Process Core Dump (PID 30479/UID 0).
feb. 18 19:50:38 manjaro-host audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump@2-30479-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
feb. 18 19:50:38 manjaro-host kernel: audit: type=1130 audit(1550515838.794:92): pid=1 uid=0 auid=4294967295 ses=4294967295 msg='unit=systemd-coredump@2-30479-0 comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
feb. 18 19:50:39 manjaro-host budgie-panel.desktop[1353]: Failed to generate minidump./app/bin/discord: line 7:     5 Segmentation fault      (core dumped) env TMPDIR=$XDG_CACHE_HOME /app/extra/discord "$@"
feb. 18 19:50:39 manjaro-host systemd-coredump[30480]: Process 11080 (discord) of user 1000 dumped core.
                                                       
                                                       Stack trace of thread 5:
                                                       #0  0x00007fc70d3142b5 n/a (/app/lib/libappindicator3.so.1.0.0)

@melroy89
Copy link

melroy89 commented Apr 27, 2019

Version 0.0.9. Same issue:

kernel.log:

Apr 28 00:51:10 melroy-pc kernel: [44249.655458] discord[4028]: segfault at ae640953000 ip 00007fab80a132b5 sp 00007fffaa3d1720 error 4 in libappindicator3.so.1.0.0[7fab80a0f000+6000]
Apr 28 00:51:10 melroy-pc kernel: [44249.655465] Code: ff 49 89 c5 48 8b 45 18 48 83 78 28 00 74 4d 48 8d 54 24 0c 48 8d 74 24 10 4c 89 ef 31 db e8 82 c0 ff ff 66 90 48 8b 44 24 10 <48> 8b 3c d8 39 5c 24 0c 7f 09 48 85 ff 0f 85 48 01 00 00 48 8b 45

libappindicator3 - allow applications to export a menu into the panel

Using Linux Mint 19.1

Any workaround? Could we use the deb file instead of Flatpack? ...

@flathub flathub deleted a comment from fishxz Apr 29, 2019
@tvannahl
Copy link
Author

A workaround under Gnome is to install the KStatusNotifierItem/AppIndicator Support. I haven't had any issues whilst running this extension.

@Leeo97one
Copy link

This is not Flatpak specific. My Discord (AUR package) also crashes regularly when I'm in a voice call. And installing the AppIndicator extension did not help.

@ZephaniahNoah
Copy link

ZephaniahNoah commented Jul 22, 2019

I have the same issue with libappindicator3.so in xfce running under Xubuntu. But I found a workaround. I removed the Item, "Notification Area" from the xfce4-panel preferences and I'm now using the "Status Notifier Plugin" Item instead. It works in pretty much the same way but doesn't crash Discord.
EDIT: I actually don't remember exactly what the original name of the bad item was. I tried different items until I found one that works. Also, I've had 0 crashes since I changed it! :D

@TheGreatestJannet

This comment has been minimized.

@TingPing

This comment has been minimized.

@TheGreatestJannet

This comment has been minimized.

@bitstrings

This comment has been minimized.

@bitstrings

This comment has been minimized.

@TingPing
Copy link
Member

TingPing commented Sep 7, 2019

There are only two options: Remove appindicator so nobody gets a tray icon, or deal with occasional crashes. We can't fix Discord.

@fgblomqvist
Copy link

Also experiencing this (both with the flatpak and the deb, so this issue should be closed) since May. Wrote a script to auto-restart Discord whenever it crashes. Annoying for my friends to hear the login/logout sound though. Sad that Discord ignores their Linux client.

@TingPing TingPing added the upstream Issues that we can't fix because they are Discord's label Sep 23, 2019
@flathub flathub deleted a comment from smvoss Jan 16, 2020
@PandorasFox
Copy link

Still seeing this:

Feb 08 19:51:37 deskfox systemd-coredump[152926]: Process 110178 (Discord) of user 1000 dumped core.
                                                  
                                                  Stack trace of thread 110178:
                                                  #0  0x00007fcf01e44ba5 n/a (libappindicator3.so + 0x7ba5)
                                                  #1  0x00007fcf25474d5a g_closure_invoke (libgobject-2.0.so.0 + 0x31d5a)
                                                  #2  0x00007fcf2546288e n/a (libgobject-2.0.so.0 + 0x1f88e)
                                                  #3  0x00007fcf2546698a g_signal_emit_valist (libgobject-2.0.so.0 + 0x2398a)
                                                  #4  0x00007fcf254677f0 g_signal_emit (libgobject-2.0.so.0 + 0x247f0)
                                                  #5  0x00007fcf01e43bab app_indicator_set_icon_full (libappindicator3.so + 0x6bab)
[...]

This is with the discord arch package; it seems to crash randomly every few hours.

@TingPing
Copy link
Member

TingPing commented Feb 9, 2020

Please stop bumping this issue. The situation is that Discord is causing a crash in libappindicator and it has nothing to do with this package.

So unless you work at Discord or are willing to make a custom patch to libappindicator to workaround this then the comment is not helpful.

@smvoss

This comment has been minimized.

@refi64
Copy link
Contributor

refi64 commented Feb 9, 2020 via email

@TingPing
Copy link
Member

TingPing commented Feb 9, 2020

The reason I leave it opened is because Discord doesn't give a damn and will never fix it, and libappindicator is a dead unmaintained library. So patching here is doable and realistically the only solution. But I guess I will have to lock it if people want to make drama.

@flathub flathub deleted a comment from Aviator-Coding Feb 9, 2020
@paulie-g
Copy link

paulie-g commented Mar 18, 2020

@TingPing No need to 'fix Discord', this is a bug in libappindicator. Installed Discord for the first time yesterday and ran into this. Thanks to @tvannahl 's solid bug report and @TingPing not closing the issue, I was able to find this issue itself, then find and fix the bug in libappindicator.

I have reported the bug with patch upstream here: https://bugs.launchpad.net/archlinux/+source/libappindicator/+bug/1867996

Below please find the patch should you wish to apply it before Ubuntu/Canonical gets their act together (which might be a long time) and your distro pulls the updated source from them (an even longer time).

--- libappindicator/src/app-indicator.c	2020-03-17 18:14:09.254862070 -0400
+++ wrk/src/app-indicator.c	2020-03-17 21:05:31.009065383 -0400
@@ -2137,7 +2137,7 @@
 		g_free (self->priv->absolute_icon_theme_path);
 		self->priv->absolute_icon_theme_path = get_real_theme_path (self);
 
-		g_signal_emit (self, signals[NEW_ICON_THEME_PATH], 0, self->priv->icon_theme_path, TRUE);
+		g_signal_emit (self, signals[NEW_ICON_THEME_PATH], 0, self->priv->icon_theme_path);
 
 		if (self->priv->dbus_registration != 0 && self->priv->connection != NULL) {
 			const gchar *theme_path = self->priv->absolute_icon_theme_path ?

I don't use flatpaks, but my understanding is you can bundle libraries. If you can ship a patched version of libappindicator in the flatpak, it'll solve the issue for everyone using it well before the fix propagates to all the distros.

@refi64
Copy link
Contributor

refi64 commented Mar 18, 2020 via email

@TingPing
Copy link
Member

Patch added, builds in progress.

@TingPing
Copy link
Member

Build published, let me know if its solved.

@paulie-g
Copy link

@TingPing It turns out there are actually multiple problems of this kind in libappindicator. Please apply the (more extensive) last patch attached to this bug:
https://bugs.launchpad.net/archlinux/+source/libappindicator/+bug/1867996

@TingPing
Copy link
Member

I already applied the newer patch. :)

@gigawhitlocks
Copy link

I needed to apply the latest patch, from 21 March 2020, in order to stop seeing these crashes. You might want to try that one too @TingPing since it wasn't yet included in the bug report listed above.

@TingPing
Copy link
Member

Well that patch doesn't cleanly apply so that will have to be looked into...

@gigawhitlocks
Copy link

gigawhitlocks commented Mar 24, 2020

It is a one line change so I did it manually. Thought it was just me doing something silly with patch sorry...

@TingPing
Copy link
Member

TingPing commented Mar 24, 2020

@gigawhitlocks If you make one to cleanly apply here I'd appreciate it: flathub/shared-modules@7181045

I actually didn't look into it at all as I'm a bit busy.

@zachschrier
Copy link

@gigawhitlocks Are you/were you able to push the clean patches to the repo? Once you do we can finally put this issue to rest, and I can't get it to work myself.

@TingPing
Copy link
Member

TingPing commented Apr 6, 2020

All patches landed. Try next update.

@TingPing TingPing closed this as completed Apr 6, 2020
@julien-f
Copy link

I still have the issue, how can I tell if I have the correct version?

@TimSC

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
upstream Issues that we can't fix because they are Discord's
Projects
None yet
Development

No branches or pull requests