summaryrefslogtreecommitdiff
path: root/sway/commands/title_format.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/commands/title_format.c')
-rw-r--r--sway/commands/title_format.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sway/commands/title_format.c b/sway/commands/title_format.c
index c9ffe8fa..ef1c8935 100644
--- a/sway/commands/title_format.c
+++ b/sway/commands/title_format.c
@@ -12,7 +12,7 @@ struct cmd_results *cmd_title_format(int argc, char **argv) {
return error;
}
struct sway_container *container = config->handler_context.container;
- if (!container->view) {
+ if (!container || !container->view) {
return cmd_results_new(CMD_INVALID, "title_format",
"Only views can have a title_format");
}