Resources are reference-counted, if another object holds a reference to a resource, it should not free it. Change the resource hashtable destroy callback to unref. Currently, this doesn't happen, since the resource hashtable is kept until the renderer is reset. However, in the next commit, the destroy callback will be used if a resource is replaced in the hashtable, and we want to keep the original resource. Furthermore, even if replace shouldn't happen, it avoids confusion and future errors if use only reference-counting mechanism. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>macos/master
parent
3ff41ae384
commit
dcc83cca07
Loading…
Reference in new issue