Apparently this can happen. Just bail out early in that case, as all the called
functions return NULL in that case.
Fixes weston-terminal for me.
Fixes:
147d7fb772a7 ("st/mesa: add a winsys buffers list in st_context")
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Charmaine Lee <charmainel@vmware.com>
{
struct st_framebuffer *cur = NULL, *stfb = NULL;
+ if (!stfbi)
+ return NULL;
+
/* Check if there is already a framebuffer object for the specified
* framebuffer interface in this context. If there is one, use it.
*/