summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordok666 <dok666>2003-05-12 16:28:59 +0000
committerdok666 <dok666>2003-05-12 16:28:59 +0000
commite971dd51ee2799716b612a02a91bcbd76d49b0ba (patch)
tree5898c66dff502d8cb3e7f1e48230fee5254f8fca
parentd1257d67d4a706cdd728031a28f2d47205a132aa (diff)
- Write back pSAREA to driverContext in clients' createScreen.
- Free driverClientMsg allocated by drivers - Fixed mmesa->setup.depth_pitch
-rw-r--r--src/mesa/drivers/dri/mga/mgabuffers.c2
-rw-r--r--src/mesa/drivers/dri/mga/server/mga_dri.c5
-rw-r--r--src/mesa/drivers/dri/radeon/server/radeon_dri.c5
-rw-r--r--src/miniglx/dri_util.c1
4 files changed, 12 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/mga/mgabuffers.c b/src/mesa/drivers/dri/mga/mgabuffers.c
index d6f49eaa6d6..cfb7893da1d 100644
--- a/src/mesa/drivers/dri/mga/mgabuffers.c
+++ b/src/mesa/drivers/dri/mga/mgabuffers.c
@@ -240,7 +240,7 @@ static void mgaUpdateBuffers(mgaContextPtr mmesa)
mmesa->setup.depth_cpp = driDrawable->depthCpp;
- mmesa->setup.depth_pitch = driDrawable->w;//depthPitch / driDrawable->depthCpp;
+ mmesa->setup.depth_pitch = driDrawable->depthPitch / driDrawable->depthCpp;
mmesa->setup.depth_offset = driDrawable->depthOffset;
mmesa->setup.maccess = (MA_memreset_disable |
diff --git a/src/mesa/drivers/dri/mga/server/mga_dri.c b/src/mesa/drivers/dri/mga/server/mga_dri.c
index ffa8fcb0f16..a6bd8f7c4f1 100644
--- a/src/mesa/drivers/dri/mga/server/mga_dri.c
+++ b/src/mesa/drivers/dri/mga/server/mga_dri.c
@@ -989,6 +989,11 @@ static void mgaHaltFBDev( struct DRIDriverContextRec *ctx )
free(ctx->driverPrivate);
ctx->driverPrivate = NULL;
}
+
+ if (ctx->driverClientMsg) {
+ free(ctx->driverClientMsg);
+ ctx->driverClientMsg = NULL;
+ }
}
diff --git a/src/mesa/drivers/dri/radeon/server/radeon_dri.c b/src/mesa/drivers/dri/radeon/server/radeon_dri.c
index 8efac506d90..3054e84013a 100644
--- a/src/mesa/drivers/dri/radeon/server/radeon_dri.c
+++ b/src/mesa/drivers/dri/radeon/server/radeon_dri.c
@@ -1225,6 +1225,11 @@ static void radeonHaltFBDev( struct DRIDriverContextRec *ctx )
free(ctx->driverPrivate);
ctx->driverPrivate = 0;
}
+
+ if (ctx->driverClientMsg) {
+ free(ctx->driverClientMsg);
+ ctx->driverClientMsg = NULL;
+ }
}
diff --git a/src/miniglx/dri_util.c b/src/miniglx/dri_util.c
index eace892cba5..c9b181203d0 100644
--- a/src/miniglx/dri_util.c
+++ b/src/miniglx/dri_util.c
@@ -675,6 +675,7 @@ __driUtilCreateScreen(struct DRIDriverRec *driver,
mprotect(psp->pSAREA, driverContext->shared.SAREASize, PROT_READ);
#endif
+ driverContext->pSAREA = psp->pSAREA;
} else {
psp->pFB = driverContext->FBAddress;
psp->pSAREA = driverContext->pSAREA;