From 2e35685fe1c8b9e324a435e5aad434b47746482b Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Thu, 18 Sep 2014 16:15:13 +0200 Subject: [PATCH] safe_shlex_split: Don't split None. --- qutebrowser/utils/utils.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/qutebrowser/utils/utils.py b/qutebrowser/utils/utils.py index a866a4b22..96070fc6b 100644 --- a/qutebrowser/utils/utils.py +++ b/qutebrowser/utils/utils.py @@ -111,6 +111,8 @@ def safe_shlex_split(s): Since shlex raises ValueError in both cases we unfortunately have to parse the exception string... """ + if s is None: + raise TypeError("Can't split None!") while True: try: return shlex.split(s)