sway: Sway sometimes crashes on reload

Please fill out the following:

[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
Core was generated by `/usr/bin/sway -d'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x00007fb4b3ce5078 in wl_event_loop_dispatch () from /usr/lib/libwayland-server.so.0
[Current thread is 1 (Thread 0x7fb4b2d15940 (LWP 2248))]
(gdb) bt full
#0  0x00007fb4b3ce5078 in wl_event_loop_dispatch () at /usr/lib/libwayland-server.so.0
#1  0x00007fb4b3ce2be7 in wl_display_run () at /usr/lib/libwayland-server.so.0
#2  0x00005556b5c14979 in server_run (server=0x5556b5c8b100 <server>) at ../sway/sway/server.c:254
        config_path = 0x0
        usage = 0x5556b5c6d250 "Usage: sway [options] [command]\n\n  -h, --help", ' ' <repeats 13 times>, "Show help message and quit.\n  -c, --config <config>  Specify a config file.\n  -C, --validate         Check the validity of the config file, th"...
        c = <optimized out>
        long_options = 
            {{name = 0x5556b5c6c33c "help", has_arg = 0, flag = 0x0, val = 104}, {name = 0x5556b5c70c18 "config", has_arg = 1, flag = 0x0, val = 99}, {name = 0x5556b5c6c341 "validate", has_arg = 0, flag = 0x0, val = 67}, {name = 0x5556b5c6c34a "debug", has_arg = 0, flag = 0x0, val = 100}, {name = 0x5556b5c6bf00 "version", has_arg = 0, flag = 0x0, val = 118}, {name = 0x5556b5c6b90f "verbose", has_arg = 0, flag = 0x0, val = 86}, {name = 0x5556b5c6c350 "get-socketpath", has_arg = 0, flag = 0x0, val = 112}, {name = 0x5556b5c6c35f "unsupported-gpu", has_arg = 0, flag = 0x0, val = 117}, {name = 0x5556b5c6c36f "my-next-gpu-wont-be-nvidia", has_arg = 0, flag = 0x0, val = 117}, {name = 0x0, has_arg = 0, flag = 0x0, val = 0}}
        validate = 0
        debug = 1
        allow_unsupported_gpu = 0
        verbose = 0
#3  main (argc=<optimized out>, argv=0x7ffe9b7036e8) at ../sway/sway/main.c:433
        config_path = 0x0
        usage = 0x5556b5c6d250 "Usage: sway [options] [command]\n\n  -h, --help", ' ' <repeats 13 times>, "Show help message and quit.\n  -c, --config <config>  Specify a config file.\n  -C, --validate         Check the validity of the config file, th"...
        c = <optimized out>
        long_options = 
            {{name = 0x5556b5c6c33c "help", has_arg = 0, flag = 0x0, val = 104}, {name = 0x5556b5c70c18 "config", has_arg = 1, flag = 0x0, val = 99}, {name = 0x5556b5c6c341 "validate", has_arg = 0, flag = 0x0, val = 67}, {name = 0x5556b5c6c34a "debug", has_arg = 0, flag = 0x0, val = 100}, {name = 0x5556b5c6bf00 "version", has_arg = 0, flag = 0x0, val = 118}, {name = 0x5556b5c6b90f "verbose", has_arg = 0, flag = 0x0, val = 86}, {name = 0x5556b5c6c350 "get-socketpath", has_arg = 0, flag = 0x0, val = 112}, {name = 0x5556b5c6c35f "unsupported-gpu", has_arg = 0, flag = 0x0, val = 117}, {name = 0x5556b5c6c36f "my-next-gpu-wont-be-nvidia", has_arg = 0, flag = 0x0, val = 117}, {name = 0x0, has_arg = 0, flag = 0x0, val = 0}}
        validate = 0
        debug = 1
        allow_unsupported_gpu = 0
        verbose = 0
  • Description:
    • I just hit the key combination for reload (bindsym $mod+Shift+c reload), with several applications running (chrome beta, firefox, foot, spotify etc.); Sway did not immediately crash, but my whole system just froze momentarily (no mouse movement, no effect on me pressing the caps lock), after after a couple of seconds, sway crashed and quit (and I found myself at the TTY login).
    • Sway does not always crash on reload (some of my apps crash, though, like Firefox), so I cannot consistently reproduce this.

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 22 (3 by maintainers)

Most upvoted comments

@zsolt-donca I’m still experiencing the same issue, so I’m asking for reopening. This time, the waybar was completely gone. Upon reloading my configuration, Firefox crashed and all the kitty terminal opened were not accepting any keyboard or mouse input.

Closing as a duplicate of #6570. Please re-open a separate issue if your backtrace is different.

@tigerjack Fair enough. Please keep us posted on your experiences.

@tigerjack I just followed the instructions on activating the address sanitizer and undefined behavior sanitizer. I’ve modified my PKGBUILD files (in the AUR packages linked in my original post) and added the appropriate flags to meson. This resulted in me no longer experiencing my original issue, which was sway crashing (and producing a stacktrace and a coredump), but instead, I’m experiencing the two issues that I’ve reported a couple of comments before. I would say that nothing is in fact fixed for me, the issue is just manifested differently.