summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/dri/dri_drawable.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/state_trackers/dri/dri_drawable.c')
-rw-r--r--src/gallium/state_trackers/dri/dri_drawable.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/gallium/state_trackers/dri/dri_drawable.c b/src/gallium/state_trackers/dri/dri_drawable.c
index 9b0ae8b..75b4cc5 100644
--- a/src/gallium/state_trackers/dri/dri_drawable.c
+++ b/src/gallium/state_trackers/dri/dri_drawable.c
@@ -33,7 +33,7 @@
#include "dri_context.h"
#include "dri_drawable.h"
#include "dri_st_api.h"
-#include "dri1.h"
+#include "dri1_helper.h"
#include "pipe/p_screen.h"
#include "util/u_format.h"
@@ -79,13 +79,10 @@ void
dri_destroy_buffer(__DRIdrawable * dPriv)
{
struct dri_drawable *drawable = dri_drawable(dPriv);
- int i;
dri1_swap_fences_clear(drawable);
- pipe_surface_reference(&drawable->dri1_surface, NULL);
- for (i = 0; i < ST_ATTACHMENT_COUNT; i++)
- pipe_texture_reference(&drawable->textures[i], NULL);
+ dri1_destroy_pipe_surface(drawable);
dri_destroy_st_framebuffer(drawable->stfb);