diff options
author | Paul Mairo <herrmpr@gmail.com> | 2023-07-22 16:01:05 +0200 |
---|---|---|
committer | Paul Mairo <herrmpr@gmail.com> | 2023-07-22 16:14:51 +0200 |
commit | 8fdf168ac0e1fd6e2ce041abd3a8869fb5225261 (patch) | |
tree | d1ff5b71f6869d40ce73f1b303bddd1a4997f052 | |
parent | 4a031f4eafd786ce22b0487389ed70514c9897ed (diff) | |
download | qutebrowser-8fdf168ac0e1fd6e2ce041abd3a8869fb5225261.tar.gz qutebrowser-8fdf168ac0e1fd6e2ce041abd3a8869fb5225261.zip |
quitter: fix prompt_queue being None at shudown
When pressing C-c if qutebrowser is not fully started yet, the prompt_queue is not
initialized and prompts for an annoying crash report.
Fixes #6827
-rw-r--r-- | doc/changelog.asciidoc | 3 | ||||
-rw-r--r-- | qutebrowser/misc/quitter.py | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/doc/changelog.asciidoc b/doc/changelog.asciidoc index b8bce1545..7eece0317 100644 --- a/doc/changelog.asciidoc +++ b/doc/changelog.asciidoc @@ -159,7 +159,7 @@ Changed the correct PID (rather than always showing the latest process, which might not be the failing one) - When a process got killed with `SIGTERM`, no error message is now displayed - anymore (unless started with `:spawn --verbose`). + anymore (unless started with `:spawn --verbose`). - When a process got killed by a signal, the signal name is now displayed in the message. - The qute-pass will now try looking up candidate pass entries based on the @@ -188,6 +188,7 @@ Fixed - Multiple rare crashes when quitting qutebrowser. - The `asciidoc2html.py` script now correctly uses the virtualenv-installed asciidoc rather than requiring a system-wide installation. +- Crash when shutting down before fully initialized - Crash with some notification servers when the server is quitting. - Crash when using QtWebKit with PAC and the file has an invalid encoding. - Crash with the "tiramisu" notification server. diff --git a/qutebrowser/misc/quitter.py b/qutebrowser/misc/quitter.py index 59e2d552f..3396dbe51 100644 --- a/qutebrowser/misc/quitter.py +++ b/qutebrowser/misc/quitter.py @@ -219,7 +219,8 @@ class Quitter(QObject): status, session)) sessions.shutdown(session, last_window=last_window) - prompt.prompt_queue.shutdown() + if prompt.prompt_queue is not None: + prompt.prompt_queue.shutdown() # If shutdown was called while we were asking a question, we're in # a still sub-eventloop (which gets quit now) and not in the main |