summaryrefslogtreecommitdiff
path: root/src/sna/sna.h
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2014-08-03 18:08:02 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2014-08-03 20:31:51 +0100
commit0b938573353aab70536d913b2d078181a3c9a1a4 (patch)
treeb3be9b31166e25b8fedc62c8949a9341b57d3a09 /src/sna/sna.h
parent4de3f9bd79d8e42f9767c9fe44d553cfb749ac65 (diff)
sna: Add some paranoid asserts around get_window_pixmap()
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/sna.h')
-rw-r--r--src/sna/sna.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/sna/sna.h b/src/sna/sna.h
index 206ecc98..498149da 100644
--- a/src/sna/sna.h
+++ b/src/sna/sna.h
@@ -188,6 +188,8 @@ static inline WindowPtr get_root_window(ScreenPtr screen)
static inline PixmapPtr get_window_pixmap(WindowPtr window)
{
+ assert(window);
+ assert(window->drawable.type != DRAWABLE_PIXMAP);
return fbGetWindowPixmap(window);
}