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

sway crashes instantly (segmentation fault) #5686

Closed
antisocrates opened this issue Sep 15, 2020 · 5 comments · Fixed by #5689
Closed

sway crashes instantly (segmentation fault) #5686

antisocrates opened this issue Sep 15, 2020 · 5 comments · Fixed by #5689
Labels
bug Not working as intended

Comments

@antisocrates
Copy link

antisocrates commented Sep 15, 2020

  • Sway Version:
    sway version 1.5-7aea4692 (Sep 15 2020, branch 'master')

  • Debug Log:
    sway.log

  • Configuration File:
    config

  • Stack Trace:
    journalctl

    coredump

  • Description:
    Starting sway from tty, instantly crashes with segmentation fault.

@antisocrates antisocrates added the bug Not working as intended label Sep 15, 2020
@sysedwinistrator
Copy link

Same here.

@alejor
Copy link

alejor commented Sep 15, 2020

Same here, instant segfault

@alejor
Copy link

alejor commented Sep 15, 2020

with this version, no segfault error: 2efecc1, so the bug was introduced on 299a159

@Emantor
Copy link
Contributor

Emantor commented Sep 15, 2020

The config pointer is not ready if we try to retrieve the timeout during cursor creation. I'll post a PR shortly.

Emantor added a commit to Emantor/sway that referenced this issue Sep 15, 2020
We can't arm the timer during cursor creation since the config may not
be ready yet. Instead arm the timer while applying the input
configuration, cursor_get_timeout() can now handle this even if the
configuration is not ready yet:

Return NULL in calls to seat_get_config*() if the config is not
initialized yet. This is required since we try to retrieve the hide
timeout from the cursor config, even if the config is not initialized.

Return 0 if we can't find any input configuration. This is okay even if
a timeout is configured, since the config will reapply the seat
configuration after load and sets up the correct timer with the correct
timeout.

Fixes swaywm#5686
@antisocrates
Copy link
Author

antisocrates commented Sep 15, 2020

#5689 Fixes the segmentation fault, and arms the timeout of hide_cursor after login.

Emantor added a commit to Emantor/sway that referenced this issue Sep 15, 2020
We can't arm the timer during cursor creation since the config may not
be ready yet. Instead arm the timer while applying the input
configuration, cursor_get_timeout() can now handle this even if the
configuration is not ready yet:

Return NULL in calls to seat_get_config*() if the config is not
initialized yet. This is required since we try to retrieve the hide
timeout from the cursor config, even if the config is not initialized.

Return 0 if we can't find any input configuration. This is okay even if
a timeout is configured, since the config will reapply the seat
configuration after load and sets up the correct timer with the correct
timeout.

Fixes swaywm#5686
Emantor added a commit to Emantor/sway that referenced this issue Sep 16, 2020
We can't arm the timer during cursor creation since the config may not
be ready yet. Instead arm the timer while applying the input
configuration, by this time the configuration has been parsed and we can
arm the hide timer.

Fixes swaywm#5686
emersion pushed a commit that referenced this issue Sep 16, 2020
We can't arm the timer during cursor creation since the config may not
be ready yet. Instead arm the timer while applying the input
configuration, by this time the configuration has been parsed and we can
arm the hide timer.

Fixes #5686
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Not working as intended
Development

Successfully merging a pull request may close this issue.

4 participants