]> git.sur5r.net Git - i3/i3/commitdiff
Bugfix: Don’t strcmp() if client->name == NULL
authorMichael Stapelberg <michael+x200@stapelberg.de>
Mon, 9 Mar 2009 05:41:04 +0000 (06:41 +0100)
committerMichael Stapelberg <michael+x200@stapelberg.de>
Mon, 9 Mar 2009 05:41:04 +0000 (06:41 +0100)
src/handlers.c

index 58e8c068af037261ff7a6401314e8cc37e23f4cf..118b73919e32cfd2f980ef8aaa16cd3bbd405a9e 100644 (file)
@@ -503,7 +503,7 @@ int handle_windowname_change(void *data, xcb_connection_t *conn, uint8_t state,
         free(new_name);
 
         /* Check if they are the same and don’t update if so */
-        if (new_len == client->name_len && strcmp(client->name, new_name) == 0) {
+        if (new_len == client->name_len && client->name != NULL && strcmp(client->name, new_name) == 0) {
                 LOG("Name did not change, not updating\n");
                 free(ucs2_name);
                 return;