Fix build with GCC 2.95.
[mesa.git] / src / glx / x11 / dri_glx.c
index 47203f50087f09088ecb53679103872f24c08100..44724d2c7d0ffce3ed21a356afca549eb4c3cc36 100644 (file)
@@ -574,6 +574,13 @@ static void driSwapBuffers(__GLXDRIdrawable *pdraw)
    (*pdraw->psc->core->swapBuffers)(pdraw->driDrawable);
 }
 
+static void driCopySubBuffer(__GLXDRIdrawable *pdraw,
+                            int x, int y, int width, int height)
+{
+    (*pdraw->psc->driCopySubBuffer->copySubBuffer)(pdraw->driDrawable,
+                                                  x, y, width, height);
+}
+
 static void driDestroyScreen(__GLXscreenConfigs *psc)
 {
     /* Free the direct rendering per screen data */
@@ -641,6 +648,8 @@ static __GLXDRIscreen *driCreateScreen(__GLXscreenConfigs *psc, int screen,
     }
 
     driBindExtensions(psc, 0);
+    if (psc->driCopySubBuffer)
+       psp->copySubBuffer = driCopySubBuffer;
 
     psp->destroyScreen = driDestroyScreen;
     psp->createContext = driCreateContext;