diff options
-rw-r--r-- | usr.bin/tmux/names.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.bin/tmux/names.c b/usr.bin/tmux/names.c index 9fa8d0c9ac8..6e897a28aa4 100644 --- a/usr.bin/tmux/names.c +++ b/usr.bin/tmux/names.c @@ -1,4 +1,4 @@ -/* $OpenBSD: names.c,v 1.40 2017/05/01 12:20:55 nicm Exp $ */ +/* $OpenBSD: names.c,v 1.41 2017/07/21 12:58:02 nicm Exp $ */ /* * Copyright (c) 2009 Nicholas Marriott <nicholas.marriott@gmail.com> @@ -151,7 +151,9 @@ parse_window_name(const char *in) if (*name != '\0') { ptr = name + strlen(name) - 1; - while (ptr > name && !isalnum((u_char)*ptr)) + while (ptr > name && + !isalnum((u_char)*ptr) && + !ispunct((u_char)*ptr)) *ptr-- = '\0'; } |