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 in elementary OS #449

Closed
tintou opened this issue Feb 8, 2021 · 6 comments
Closed

Frequent crashes in elementary OS #449

tintou opened this issue Feb 8, 2021 · 6 comments
Assignees
Milestone

Comments

@tintou
Copy link
Contributor

tintou commented Feb 8, 2021

Describe the bug

I found in the system logs that touchegg is often crashing

Logs

Here is tha backtrace from gdb:

Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/bin/touchegg --daemon'.
Program terminated with signal SIGABRT, Aborted.
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
50	../sysdeps/unix/sysv/linux/raise.c: Aucun fichier ou dossier de ce type.
[Current thread is 1 (Thread 0x7f5d3de88a80 (LWP 10547))]
(gdb) bt
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
#1  0x00007f5d3ecde859 in __GI_abort () at abort.c:79
#2  0x00007f5d3f0b3951 in __gnu_cxx::__verbose_terminate_handler() () at ../../../../src/libstdc++-v3/libsupc++/vterminate.cc:95
#3  0x00007f5d3f0bf47c in __cxxabiv1::__terminate(void (*)()) (handler=<optimized out>) at ../../../../src/libstdc++-v3/libsupc++/eh_terminate.cc:48
#4  0x00007f5d3f0bf4e7 in std::terminate() () at ../../../../src/libstdc++-v3/libsupc++/eh_terminate.cc:58
#5  0x00007f5d3f0bf799 in __cxxabiv1::__cxa_throw(void*, std::type_info*, void (*)(void*))
    (obj=obj@entry=0x55f93a5713a0, tinfo=0x55f93a04bc80 <typeinfo for std::runtime_error>, dest=0x7f5d3f0d5410 <std::runtime_error::~runtime_error()>) at ../../../../src/libstdc++-v3/libsupc++/eh_throw.cc:95
#6  0x000055f93a00fba4 in LibinputGestureGatherer::openRestricted(char const*, int, void*) (path=<optimized out>, flags=<optimized out>) at ./src/gesture-gatherer/libinput-gesture-gatherer.cpp:147
#7  0x00007f5d40323e88 in evdev_device_create (seat=seat@entry=0x55f93a588790, udev_device=udev_device@entry=0x55f93a5c6e50) at ../src/evdev.c:2168
#8  0x00007f5d4034035f in device_added (udev_device=0x55f93a5c6e50, input=0x55f93a56d5a0, seat_name=0x7f5d4034c488 <default_seat_name> "default") at ../src/udev-seat.c:83
#9  0x00007f5d4034059d in evdev_udev_handler (data=0x55f93a56d5a0) at ../src/udev-seat.c:194
#10 0x00007f5d4031d6cf in libinput_dispatch (libinput=0x55f93a56d5a0) at ../src/libinput.c:2116
#11 0x000055f93a01e039 in LibinputGestureGatherer::run() (this=0x7ffff3bf57a0) at ./src/gesture-gatherer/libinput-gesture-gatherer.cpp:88
#12 0x000055f93a0114b4 in main(int, char**) (argc=<optimized out>, argv=<optimized out>) at ./src/main.cpp:107

Your environment

  • Version of Touchégg: 2.0.6
  • Operating System: elementary OS 6
  • Desktop Environment: Pantheon
@JoseExposito
Copy link
Owner

Hi!

Thanks for the detailed bug report.

It looks like the crash happens when a new device is added, here:
https://github.com/JoseExposito/touchegg/blob/master/src/gesture-gatherer/libinput-gesture-gatherer.cpp#L146

It is kind of weird that that code is crashing now because the last meaningful change to that file (other that header and logs updates) is from the 19th of December 2020.

Did you recently add a new device to your setup? Or maybe you connected a new device in the moment of the crash?

Because Cassidy is also experimenting crashes... Do you know if something changed on elementary related to input devices? I can think of firmware updates, but I doubt it is related.

@tintou
Copy link
Contributor Author

tintou commented Feb 10, 2021

I don't know if this is related but I always have a Logitech mouse attached to my monitor so when I move I unplug my monitor and that means that the USB mouse disappears.

@JoseExposito
Copy link
Owner

Did you noticed if the crash happened when you plugged in the mouse? The log points to device_added, so it could be related.

@JoseExposito
Copy link
Owner

OK, just got a crash, but in my case with error:

GLib:ERROR:../glib/gvarianttypeinfo.c:186:g_variant_type_info_check: assertion failed: (0 <= index && index < 24)

Have you found a similar log?

The core dump points to:
https://github.com/JoseExposito/touchegg/blob/master/src/daemon/daemon-server.cpp#L118

I'm not sure if I need to sink the reference, some comments on the internet point into that direction. I'm going to test it and see if that fixes it.

@danirabbit
Copy link
Contributor

Just wanted to add some more info. I'm also experiencing some pretty regular crashes. I'm on a touchscreen laptop no external devices connected:

daniel@elementary-os:~$ sudo coredumpctl debug /usr/bin/touchegg
           PID: 63299 (touchegg)
           UID: 0 (root)
           GID: 107 (input)
        Signal: 6 (ABRT)
     Timestamp: Thu 2021-02-11 12:12:56 PST (3min 30s ago)
  Command Line: /usr/bin/touchegg --daemon
    Executable: /usr/bin/touchegg
 Control Group: /system.slice/touchegg.service
          Unit: touchegg.service
         Slice: system.slice
       Boot ID: b168bec951a74c4d9d9a46950459657b
    Machine ID: ee05690690e899bb54a525485f4037e6
      Hostname: elementary-os
       Storage: /var/lib/systemd/coredump/core.touchegg.0.b168bec951a74c4d9d9a46950459657b.63299.1613074376000000000000.lz4
       Message: Process 63299 (touchegg) of user 0 dumped core.
                
                Stack trace of thread 63299:
                #0  0x00007f14c6a2318b __GI_raise (libc.so.6 + 0x4618b)
                #1  0x00007f14c6a02859 __GI_abort (libc.so.6 + 0x25859)
                #2  0x00007f14c7a53b43 n/a (libglib-2.0.so.0 + 0x1db43)
                #3  0x00007f14c7ab0b2f g_assertion_message_expr (libglib-2.0.so.0 + 0x7ab2f)
                #4  0x00007f14c7acec76 n/a (libglib-2.0.so.0 + 0x98c76)
                #5  0x00007f14c7aced2f g_variant_type_info_get_type_string (libglib-2.0.so.0 + 0x98d2f)
                #6  0x00007f14c7ac0f7d g_variant_is_of_type (libglib-2.0.so.0 + 0x8af7d)
                #7  0x00007f14c70b16b7 g_dbus_connection_emit_signal (libgio-2.0.so.0 + 0x1126b7)
                #8  0x00005626c60eaac5 _ZN12DaemonServer4sendERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt10unique_ptrI7GestureSt14default_deleteIS9_EE (touchegg + 0x2aac5)
                #9  0x00005626c60eb146 _ZN12DaemonServer15onGestureUpdateESt10unique_ptrI7GestureSt14default_deleteIS1_EE (touchegg + 0x2b146)
                #10 0x00005626c60ef25d _ZN20LininputSwipeHandler17handleSwipeUpdateEP14libinput_event (touchegg + 0x2f25d)
                #11 0x00005626c60ee550 _ZN23LibinputGestureGatherer11handleEventEP14libinput_event (touchegg + 0x2e550)
                #12 0x00005626c60ee642 _ZN23LibinputGestureGatherer3runEv (touchegg + 0x2e642)
                #13 0x00005626c60debee main (touchegg + 0x1ebee)
                #14 0x00007f14c6a040b3 __libc_start_main (libc.so.6 + 0x270b3)
                #15 0x00005626c60df52e _start (touchegg + 0x1f52e)
                
                Stack trace of thread 63312:
                #0  0x00007f14c6af2aff __GI___poll (libc.so.6 + 0x115aff)
                #1  0x00007f14c7a8818e n/a (libglib-2.0.so.0 + 0x5218e)
                #2  0x00007f14c7a882c3 g_main_context_iteration (libglib-2.0.so.0 + 0x522c3)
                #3  0x00007f14c7a88311 n/a (libglib-2.0.so.0 + 0x52311)
                #4  0x00007f14c7ab1911 n/a (libglib-2.0.so.0 + 0x7b911)
                #5  0x00007f14c6f23609 start_thread (libpthread.so.0 + 0x9609)
                #6  0x00007f14c6aff293 __clone (libc.so.6 + 0x122293)
                
                Stack trace of thread 63313:
                #0  0x00007f14c6af2aff __GI___poll (libc.so.6 + 0x115aff)
                #1  0x00007f14c7a8818e n/a (libglib-2.0.so.0 + 0x5218e)
                #2  0x00007f14c7a88513 g_main_loop_run (libglib-2.0.so.0 + 0x52513)
                #3  0x00007f14c6e0fd84 n/a (libstdc++.so.6 + 0xd6d84)
                #4  0x00007f14c6f23609 start_thread (libpthread.so.0 + 0x9609)
                #5  0x00007f14c6aff293 __clone (libc.so.6 + 0x122293)
                
                Stack trace of thread 63318:
                #0  0x00007f14c6af2aff __GI___poll (libc.so.6 + 0x115aff)
                #1  0x00007f14c7a8818e n/a (libglib-2.0.so.0 + 0x5218e)
                #2  0x00007f14c7a88513 g_main_loop_run (libglib-2.0.so.0 + 0x52513)
                #3  0x00007f14c70bdeda n/a (libgio-2.0.so.0 + 0x11eeda)
                #4  0x00007f14c7ab1911 n/a (libglib-2.0.so.0 + 0x7b911)
                #5  0x00007f14c6f23609 start_thread (libpthread.so.0 + 0x9609)
                #6  0x00007f14c6aff293 __clone (libc.so.6 + 0x122293)

GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/bin/touchegg...
(No debugging symbols found in /usr/bin/touchegg)
[New LWP 63299]
[New LWP 63312]
[New LWP 63313]
[New LWP 63318]

warning: Unexpected size of section `.reg-xstate/63299' in core file.
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `/usr/bin/touchegg --daemon'.
Program terminated with signal SIGABRT, Aborted.

warning: Unexpected size of section `.reg-xstate/63299' in core file.
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
50	../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
[Current thread is 1 (Thread 0x7f14c5bafa80 (LWP 63299))]
(gdb) bt
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
#1  0x00007f14c6a02859 in __GI_abort () at abort.c:79
#2  0x00007f14c7a53b43 in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x00007f14c7ab0b2f in g_assertion_message_expr () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007f14c7acec76 in  () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x00007f14c7aced2f in g_variant_type_info_get_type_string () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#6  0x00007f14c7ac0f7d in g_variant_is_of_type () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#7  0x00007f14c70b16b7 in g_dbus_connection_emit_signal () at /lib/x86_64-linux-gnu/libgio-2.0.so.0
#8  0x00005626c60eaac5 in DaemonServer::send(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::unique_ptr<Gesture, std::default_delete<Gesture> >) ()
#9  0x00005626c60eb146 in DaemonServer::onGestureUpdate(std::unique_ptr<Gesture, std::default_delete<Gesture> >) ()
#10 0x00005626c60ef25d in LininputSwipeHandler::handleSwipeUpdate(libinput_event*) ()
#11 0x00005626c60ee550 in LibinputGestureGatherer::handleEvent(libinput_event*) ()
#12 0x00005626c60ee642 in LibinputGestureGatherer::run() ()
#13 0x00005626c60debee in main ()

@JoseExposito JoseExposito self-assigned this Feb 12, 2021
@JoseExposito JoseExposito added this to the 2.0.8 milestone Feb 12, 2021
@JoseExposito
Copy link
Owner

Hi! Thanks for the extra logs. I just merged a fix in master, I'll be running a few days to make sure the crash is not happening anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants