diff options
author | Maarten Maathuis <madman2003@gmail.com> | 2008-12-26 16:38:27 +0100 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2009-01-09 11:03:47 -0800 |
commit | 2056c10d12f6b4facf628b861230f9b0a13f3a73 (patch) | |
tree | 2334be9d5759a001515a41e0d667a33dee47b4e2 /exa | |
parent | 4130761f151ff5414694472e1dc29d8f2893f10e (diff) |
exa: Allow drivers to set non-NULL devPrivate.ptr for !offscreen pixmaps.
(cherry picked from commit 3534a5e5d9c5af85149c799f324257f89507fa23)
Diffstat (limited to 'exa')
-rw-r--r-- | exa/exa.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -314,6 +314,11 @@ exaCreatePixmap(ScreenPtr pScreen, int w, int h, int depth, datasize = h * paddedWidth; + /* Set this before driver hooks, to allow for !offscreen pixmaps. + * !offscreen pixmaps have a valid pointer at all times. + */ + pPixmap->devPrivate.ptr = NULL; + pExaPixmap->driverPriv = pExaScr->info->CreatePixmap(pScreen, datasize, 0); if (!pExaPixmap->driverPriv) { fbDestroyPixmap(pPixmap); @@ -326,7 +331,6 @@ exaCreatePixmap(ScreenPtr pScreen, int w, int h, int depth, pExaPixmap->fb_ptr = NULL; pExaPixmap->pDamage = NULL; pExaPixmap->sys_ptr = pPixmap->devPrivate.ptr; - pPixmap->devPrivate.ptr = NULL; } else { pExaPixmap->driverPriv = NULL; |