summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c
diff options
context:
space:
mode:
authorEmil Velikov <emil.l.velikov@gmail.com>2014-02-10 20:03:19 +0000
committerEmil Velikov <emil.l.velikov@gmail.com>2014-02-22 03:26:28 +0000
commited092a8e1f7006a57031299c5429a5952e5602e2 (patch)
treea24f4dea77d166ceb00fc5ca5829b77a6f474a2f /src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c
parent636ac989b2ef4ada8239a49521cf37be2fa81c0c (diff)
downloadexternal_mesa3d-ed092a8e1f7006a57031299c5429a5952e5602e2.zip
external_mesa3d-ed092a8e1f7006a57031299c5429a5952e5602e2.tar.gz
external_mesa3d-ed092a8e1f7006a57031299c5429a5952e5602e2.tar.bz2
pipe-loader: destroy sw_winsys on sw_release
The sw pipe-loader implicitly handles winsys_create, thus we it would make sense to implicitly destroy it upon releasing the loader. Currently we leak the sw_winsys when releasing the pipe-loader. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com> Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Diffstat (limited to 'src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c')
-rw-r--r--src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c b/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c
index 95a4f84..fd3d989 100644
--- a/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c
+++ b/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c
@@ -75,6 +75,9 @@ pipe_loader_sw_release(struct pipe_loader_device **dev)
{
struct pipe_loader_sw_device *sdev = pipe_loader_sw_device(*dev);
+ if (sdev->ws && sdev->ws->destroy)
+ sdev->ws->destroy(sdev->ws);
+
if (sdev->lib)
util_dl_close(sdev->lib);