sna: Add a pair of asserts to track down a NULL pointer dereference
Looks like the assumption for the location of the data is invalid, allocation failure, perhaps? References: https://bugs.freedesktop.org/show_bug.cgi?id=47597 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
d376a960df
commit
771090f25d
|
|
@ -460,6 +460,8 @@ static struct kgem_bo *upload(struct sna *sna,
|
|||
priv->mapped = false;
|
||||
}
|
||||
if (pixmap->devPrivate.ptr == NULL) {
|
||||
assert(priv->ptr);
|
||||
assert(priv->stride);
|
||||
pixmap->devPrivate.ptr = priv->ptr;
|
||||
pixmap->devKind = priv->stride;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue