From: Jakob Bornecrantz Date: Thu, 27 Jan 2011 13:58:30 +0000 (+0100) Subject: util: Fix leak of transfers in upload manager X-Git-Tag: mesa-7.11-rc1~2430 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3451ee056c8703f0d09bfab33d5fa224d4649bc4;p=platform%2Fupstream%2Fmesa.git util: Fix leak of transfers in upload manager --- diff --git a/src/gallium/auxiliary/util/u_upload_mgr.c b/src/gallium/auxiliary/util/u_upload_mgr.c index 3b3d5b4..865dab8 100644 --- a/src/gallium/auxiliary/util/u_upload_mgr.c +++ b/src/gallium/auxiliary/util/u_upload_mgr.c @@ -86,6 +86,7 @@ void u_upload_flush( struct u_upload_mgr *upload ) /* Unmap and unreference the upload buffer. */ if (upload->transfer) { pipe_transfer_unmap(upload->pipe, upload->transfer); + pipe_transfer_destroy(upload->pipe, upload->transfer); upload->transfer = NULL; } pipe_resource_reference( &upload->buffer, NULL );