This repository was archived by the owner on Nov 1, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -31,15 +31,15 @@ struct workspace_state {
3131
3232static void copy_state (struct workspace_state * current ,
3333 struct workspace_state * pending ) {
34- if (current -> name && pending -> name ) {
35- free (current -> name );
36- }
3734
3835 current -> state = pending -> state ;
3936 wl_array_copy (& current -> coordinates , & pending -> coordinates );
4037
41- current -> name = pending -> name ;
42- pending -> name = NULL ;
38+ if (pending -> name ) {
39+ free (current -> name );
40+ current -> name = pending -> name ;
41+ pending -> name = NULL ;
42+ }
4343}
4444
4545struct workspace_v1 {
@@ -309,8 +309,6 @@ int main(int argc, char **argv) {
309309 }
310310 wl_display_roundtrip (display ); // load workspace groups
311311 wl_display_roundtrip (display ); // load details
312- wl_display_roundtrip (display ); // load details
313- wl_display_roundtrip (display ); // load details
314312
315313 if (focus_name != NULL ) {
316314 struct workspace_v1 * focus = workspace_by_name_or_bail (focus_name );
@@ -325,6 +323,7 @@ int main(int argc, char **argv) {
325323 }
326324 }
327325 zwlr_workspace_handle_v1_activate (focus -> handle );
326+ zwlr_workspace_manager_v1_commit (workspace_manager );
328327 }
329328
330329 wl_display_flush (display );
You can’t perform that action at this time.
0 commit comments