Allow :. in names again, forbidding them is overly pernickety. Only

forbid invalid UTF-8 and #(.
This commit is contained in:
nicm
2026-06-29 18:17:28 +00:00
parent bcd54d12d8
commit 65a032b205
12 changed files with 35 additions and 63 deletions

View File

@@ -237,10 +237,7 @@ screen_set_title(struct screen *s, const char *title, int untrusted)
{
char *new_title;
if (untrusted)
new_title = clean_name(title, "#");
else
new_title = clean_name(title, "");
new_title = clean_name(title, untrusted);
if (new_title == NULL)
return (0);
free(s->title);
@@ -254,10 +251,7 @@ screen_set_path(struct screen *s, const char *path, int untrusted)
{
char *new_path;
if (untrusted)
new_path = clean_name(path, "#");
else
new_path = clean_name(path, "");
new_path = clean_name(path, untrusted);
if (new_path == NULL)
return (0);
free(s->path);