fix(ewmh): Include last desktop name
This commit is contained in:
parent
b25fa46ac2
commit
6fe411ea9e
@ -87,8 +87,9 @@ namespace ewmh_util {
|
||||
|
||||
vector<string> names;
|
||||
char buffer[BUFSIZ];
|
||||
size_t len{0};
|
||||
|
||||
for (size_t n = 0, len = 0; n < reply.strings_len; n++) {
|
||||
for (size_t n = 0; n < reply.strings_len; n++) {
|
||||
if (reply.strings[n] == '\0') {
|
||||
names.emplace_back(buffer, len);
|
||||
len = 0;
|
||||
@ -97,6 +98,10 @@ namespace ewmh_util {
|
||||
}
|
||||
}
|
||||
|
||||
if (len) {
|
||||
names.emplace_back(buffer, len);
|
||||
}
|
||||
|
||||
return names;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user