From db92af68e99bf0b02102ef75f48dce31594aee10 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 8 Jan 2018 13:54:08 +0530 Subject: [PATCH] Fix a couple of typos --- kitty/child.c | 2 +- kitty/session.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/kitty/child.c b/kitty/child.c index ea6c14073..3fb3f8861 100644 --- a/kitty/child.c +++ b/kitty/child.c @@ -96,7 +96,7 @@ spawn(PyObject *self UNUSED, PyObject *args) { #undef exit_on_err free(argv); free(env); - if (pid == -1) return NULL; + if (PyErr_Occurred()) return NULL; return PyLong_FromLong(pid); } diff --git a/kitty/session.py b/kitty/session.py index 6685d2fb3..3b5daf17c 100644 --- a/kitty/session.py +++ b/kitty/session.py @@ -111,9 +111,9 @@ def create_session(opts, args=None, special_window=None, cwd_from=None): cmd = args.args if args and args.args else [shell_path] from kitty.tabs import SpecialWindow if getattr(args, 'title', None): - ans.add_window(SpecialWindow(cmd, override_title=args.title, cwd_from=cwd_from)) + ans.add_special_window(SpecialWindow(cmd, override_title=args.title, cwd_from=cwd_from)) else: - ans.add_window(SpecialWindow(cmd, cwd_from=cwd_from)) + ans.add_special_window(SpecialWindow(cmd, cwd_from=cwd_from)) else: ans.add_special_window(special_window) return ans