diff options
author | Vinson Lee <[email protected]> | 2009-11-28 23:22:31 -0500 |
---|---|---|
committer | Vinson Lee <[email protected]> | 2009-12-06 01:01:55 -0800 |
commit | c994f08eb1ec2a4bbaa44fbd6d35e7ff033d5c3c (patch) | |
tree | 805790bce8fcca04c5118222b459d8c2fad854fc /src/mesa | |
parent | f622b649fb0c55b1640997f9d32ea327743519a1 (diff) |
dri: Fix potential null pointer dereference in driBindContext.
(cherry picked from commit 919898e92fa23ff71a59d86a46ff0886a6f34e4d)
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/common/dri_util.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c index 439f66a7b88..da81ec9de51 100644 --- a/src/mesa/drivers/dri/common/dri_util.c +++ b/src/mesa/drivers/dri/common/dri_util.c @@ -167,11 +167,12 @@ static int driBindContext(__DRIcontext *pcp, __DRIdrawable *pdp, __DRIdrawable *prp) { - __DRIscreenPrivate *psp = pcp->driScreenPriv; + __DRIscreenPrivate *psp; /* Bind the drawable to the context */ if (pcp) { + psp = pcp->driScreenPriv; pcp->driDrawablePriv = pdp; pcp->driReadablePriv = prp; if (pdp) { |