Skip to content

Panic after closing windows during swiping gesture #1588

@19MisterX98

Description

@19MisterX98

Steps to reproduce:

  • Open a window on the last to workspaces.
  • Go to the last workspace with a Window
  • Touch the touchpad with four fingers, initiating a swipe gesture but don't move yet
  • Close the window via Super+q
  • Swipe to the workspace with the other window
  • Close the window via Super+q
  • Lift fingers from touchpad.
  • The compositor restarts
                    set.previously_active
                        .map(|(idx, start)| (&set.workspaces[idx], start))

This bit of code assumes that the previous workspace still exists even though it doesn't in this case.
I'll pr the fix in a min.

Aug 16 23:36:29 pop-os cosmic-comp[1827]: thread 'main' panicked at 'index out of bounds: the len is 1 but the index is 1': src/shell/mod.rs:1149
                                             0: <unknown>
                                             1: <unknown>
                                             2: <unknown>
                                             3: <unknown>
                                             4: <unknown>
                                             5: <unknown>
                                             6: <unknown>
                                             7: <unknown>
                                             8: <unknown>
                                             9: <unknown>
                                            10: <unknown>
                                            11: <unknown>
                                            12: <unknown>
                                            13: <unknown>
                                            14: <unknown>
                                            15: <unknown>
                                            16: __libc_start_main
                                            17: <unknown>
Aug 16 23:36:29 pop-os cosmic-comp[1827]: thread 'surface-eDP-1' panicked at 'index out of bounds: the len is 1 but the index is 1': src/shell/mod.rs:1149
                                             0: <unknown>
                                             1: <unknown>
                                             2: <unknown>
                                             3: <unknown>
                                             4: <unknown>
                                             5: <unknown>
                                             6: <unknown>
                                             7: <unknown>
                                             8: <unknown>
                                             9: <unknown>
                                            10: <unknown>
                                            11: <unknown>
                                            12: <unknown>
                                            13: <unknown>
                                            14: <unknown>
                                            15: <unknown>
Aug 16 23:36:30 pop-os kdeconnectd[1961]: The Wayland connection broke. Did the Wayland compositor die?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions