cogl-auto-texture: Avoid a double-free crash
authorDaniel van Vugt <daniel.van.vugt@canonical.com>
Thu, 11 Oct 2018 06:49:22 +0000 (06:49 +0000)
committerSimon McVittie <smcv@debian.org>
Sat, 27 Apr 2019 23:13:35 +0000 (00:13 +0100)
commit0ceb989f6c68c53e663922e81ce6b72aa3ab0832
tree5a98a8fae52db31f13e7314e3925945b2cc0c949
parent028c2a6f0bf8b847c711f7fc9ca51a54c31e5a1a
cogl-auto-texture: Avoid a double-free crash

If texture allocation fails (e.g. on an old GPU with size limit 2048)
then `cogl_texture_new_with_size` was trying to use the same CoglError
twice. The second time was after it had already been freed.

Bug reported and fix provided by Gert van de Kraats.

(cherry picked from commit d21478b0f0163b0688abe065a7009b33453d0d00)

Bug-Ubuntu: https://launchpad.net/bugs/1790525
Applied-upstream: 3.30.3, commit:1cb21877edd9c7c5bc991527ae70879b1e9fece0

Gbp-Pq: Name cogl-auto-texture-Avoid-a-double-free-crash.patch
cogl/cogl/deprecated/cogl-auto-texture.c