Bugfix: Use both parts of WM_CLASS (it contains instance and class) (Thanks fallen)
Actually, WM_CLASS contains two null-terminated strings, so we cannot use asprintf() to get its value but rather use strdup() to get both of them. Both values are compared when a client is matched against a wm_class/title combination (for assignments for example).
This commit is contained in:
@ -378,8 +378,10 @@ struct Client {
|
||||
* in. If set to true, legacy window names are ignored. */
|
||||
bool uses_net_wm_name;
|
||||
|
||||
/** Holds the WM_CLASS, useful for matching the client in commands */
|
||||
char *window_class;
|
||||
/** Holds the WM_CLASS (which consists of two strings, the instance
|
||||
* and the class), useful for matching the client in commands */
|
||||
char *window_class_instance;
|
||||
char *window_class_class;
|
||||
|
||||
/** Holds the client’s mark, for vim-like jumping */
|
||||
char *mark;
|
||||
|
Reference in New Issue
Block a user