Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xrender: fix leak in deinit #979

Merged
merged 1 commit into from
Dec 22, 2022
Merged

xrender: fix leak in deinit #979

merged 1 commit into from
Dec 22, 2022

Conversation

absolutelynothelix
Copy link
Collaborator

fixes at least #960

i'm on fire today 😎

vibin.mp4

@codecov
Copy link

codecov bot commented Dec 21, 2022

Codecov Report

Merging #979 (dd9ffec) into next (48d3a0b) will increase coverage by 0.14%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             next     #979      +/-   ##
==========================================
+ Coverage   37.68%   37.82%   +0.14%     
==========================================
  Files          48       48              
  Lines       10847    10849       +2     
==========================================
+ Hits         4088     4104      +16     
+ Misses       6759     6745      -14     
Impacted Files Coverage Δ
src/backend/xrender/xrender.c 0.00% <0.00%> (ø)
src/picom.c 65.93% <0.00%> (+0.59%) ⬆️
src/win.c 68.25% <0.00%> (+0.80%) ⬆️

@yshui
Copy link
Owner

yshui commented Dec 21, 2022

🔥

@yshui
Copy link
Owner

yshui commented Dec 21, 2022

can you also add a if (xd->back[i] != XCB_NONE) for me?

@absolutelynothelix
Copy link
Collaborator Author

can you also add a if (xd->back[i] != XCB_NONE) for me?

looking at the backend_xrender_init i believe it should look like this?

        for (int i = 0; i < 3; i++) {
                if (xd->back[i] != XCB_NONE) {
                        xcb_render_free_picture(xd->base.c, xd->back[i]);
                }
                if (xd->back_pixmap[i] != XCB_NONE) {
                        xcb_free_pixmap(xd->base.c, xd->back_pixmap[i]);
                }
        }

@yshui
Copy link
Owner

yshui commented Dec 21, 2022

yep!

@absolutelynothelix
Copy link
Collaborator Author

ah, give me a second to figure out how do i commit it properly

and check should we actually free something

fixes at least yshui#960
@absolutelynothelix
Copy link
Collaborator Author

done

@yshui
Copy link
Owner

yshui commented Dec 22, 2022

thank you!

@yshui yshui merged commit 5457d76 into yshui:next Dec 22, 2022
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.

2 participants