Allow empty name with new-window again, from Jacob Koziej.

This commit is contained in:
nicm
2026-07-09 07:19:24 +00:00
parent 1fefb80445
commit dea309cf8d

View File

@@ -179,7 +179,7 @@ spawn_window(struct spawn_context *sc, char **cause)
/* Set the name of the new window. */
if (~sc->flags & SPAWN_RESPAWN) {
free(w->name);
if (sc->name == NULL || *sc->name == '\0')
if (sc->name == NULL)
w->name = default_window_name(w);
else {
w->name = xstrdup(sc->name);