mirror of
https://github.com/Zedfrigg/ironbar.git
synced 2025-04-19 19:34:24 +02:00
fix(ipc): regression - reload not working due to #592
let index = match index { Some(index) => index - 1, None => { lock!(map).push(monitor_name.clone()); lock!(map).len() - 1 } }; //This causes index to underflow //Expected Output is something like 0, 1, etc //But sometimes we go back around to 18446744073709551615 //Removing the -1 here seems to work ok with multi monitor, and reload is not broken anymore Some(index) => index,
This commit is contained in:
parent
3b6480f3f2
commit
4ad4b0e070
1 changed files with 1 additions and 1 deletions
|
@ -353,7 +353,7 @@ fn load_output_bars(
|
|||
|
||||
let index = lock!(map).iter().position(|n| n == monitor_name);
|
||||
let index = match index {
|
||||
Some(index) => index - 1,
|
||||
Some(index) => index,
|
||||
None => {
|
||||
lock!(map).push(monitor_name.clone());
|
||||
lock!(map).len() - 1
|
||||
|
|
Loading…
Add table
Reference in a new issue