From 2065f292ab5b7d4f5b84559c81fd0edf0f73a2ac Mon Sep 17 00:00:00 2001 From: Nick Ginther Date: Wed, 25 May 2016 16:45:06 -0500 Subject: [PATCH] fix crash on empty parts[] (#1523) --- qutebrowser/completion/completer.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/qutebrowser/completion/completer.py b/qutebrowser/completion/completer.py index ffc4db3a0..2f2823611 100644 --- a/qutebrowser/completion/completer.py +++ b/qutebrowser/completion/completer.py @@ -204,6 +204,8 @@ class Completer(QObject): parts, cursor_part = self._filter_cmdline_parts(parts, cursor_part) log.completion.debug("After filtering flags: parts {}, cursor_part " "{}".format(parts, cursor_part)) + if not parts: + return None if cursor_part == 0: # '|' or 'set|' model = instances.get(usertypes.Completion.command)