mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 16:08:04 +02:00
intel: Don't call intelDestroyContext if there is no context to destroy
Some error paths in the device-specific context creation functions can exit
before the deintel_context structure is allocated.
NOTE: This is a candidate for the 9.0 branch.
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=53618
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=54301
(cherry picked from commit 22897c7497)
This commit is contained in:
parent
5174eed793
commit
a87b0110b9
1 changed files with 3 additions and 1 deletions
|
|
@ -820,7 +820,9 @@ intelCreateContext(gl_api api,
|
|||
if (success)
|
||||
return true;
|
||||
|
||||
intelDestroyContext(driContextPriv);
|
||||
if (driContextPriv->driverPrivate != NULL)
|
||||
intelDestroyContext(driContextPriv);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue