UI: Enter graphics context before destroying texture
Fixes a memory leak where the texture would not be properly freed.
This commit is contained in:
parent
2a92555f58
commit
53ba6c0350
1 changed files with 2 additions and 0 deletions
|
|
@ -29,7 +29,9 @@ OBSBasicPreview::OBSBasicPreview(QWidget *parent, Qt::WindowFlags flags)
|
|||
OBSBasicPreview::~OBSBasicPreview()
|
||||
{
|
||||
if (overflow) {
|
||||
obs_enter_graphics();
|
||||
gs_texture_destroy(overflow);
|
||||
obs_leave_graphics();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue