Skip to content

Conversation

@patrick96
Copy link
Member

@patrick96 patrick96 commented Sep 4, 2022

What type of PR is this? (check all applicable)

  • Refactor
  • Feature
  • Bug Fix
  • Optimization
  • Documentation Update
  • Other: Replace this with a description of the type of this PR

Description

The background_manager used the root window depth for creating its
pixmaps, but when the root pixmap has a different depth, this causes the
copy_area_checked call to fail and crash the bar.

We now load the root pixmap before finding the visual and creating the
slice pixmaps.

Related Issues & Documents

Fixes #2798

Documentation (check all applicable)

  • This PR requires changes to the Wiki documentation (describe the changes)
  • This PR requires changes to the documentation inside the git repo (please add them to the PR).
  • Does not require documentation changes

The background_manager used the root window depth for creating its
pixmaps, but when the root pixmap has a different depth, this causes the
copy_area_checked call to fail and crash the bar.

We now load the root pixmap before finding the visual and creating the
slice pixmaps.

Fixes polybar#2798
@patrick96 patrick96 force-pushed the fix/2798-root-pixmap-depth branch from 35dc550 to 29211e8 Compare September 4, 2022 16:54
@patrick96 patrick96 mentioned this pull request Sep 4, 2022
4 tasks
@codecov
Copy link

codecov bot commented Sep 4, 2022

Codecov Report

Merging #2813 (29211e8) into master (d817080) will decrease coverage by 0.05%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##           master    #2813      +/-   ##
==========================================
- Coverage   13.49%   13.44%   -0.06%     
==========================================
  Files         152      151       -1     
  Lines       11422    11465      +43     
==========================================
  Hits         1541     1541              
- Misses       9881     9924      +43     
Flag Coverage Δ
unittests 13.44% <0.00%> (-0.06%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/components/bar.cpp 0.00% <0.00%> (ø)
src/x11/background_manager.cpp 0.00% <0.00%> (ø)
src/x11/tray_manager.cpp 0.00% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@patrick96 patrick96 merged commit 053a7eb into polybar:master Sep 5, 2022
@patrick96 patrick96 deleted the fix/2798-root-pixmap-depth branch September 5, 2022 07:58
@patrick96 patrick96 mentioned this pull request Nov 5, 2023
24 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

xcb fatal error[Bug]:

1 participant