Signed-off-by: Matteo Bruni mbruni@codeweavers.com --- dlls/wined3d/wined3d_private.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 11da88aff8a..3a12f5ef261 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -6744,7 +6744,8 @@ static inline void wined3d_context_gl_reference_bo(struct wined3d_context_gl *co static inline void wined3d_context_gl_reference_buffer(struct wined3d_context_gl *context_gl, struct wined3d_buffer *buffer) { - wined3d_context_gl_reference_bo(context_gl, wined3d_bo_gl(buffer->buffer_object)); + if (buffer->buffer_object) + wined3d_context_gl_reference_bo(context_gl, wined3d_bo_gl(buffer->buffer_object)); }
static inline bool wined3d_map_persistent(void)