From 7809efc8c32520e6b25c143ee3276edbf534ed14 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Mon, 30 Aug 2004 09:01:50 +0000 Subject: drm-memory patch, cleans up alloc/free and makes calloc look more libc like --- shared/radeon_state.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'shared/radeon_state.c') diff --git a/shared/radeon_state.c b/shared/radeon_state.c index cdbd7a8e..e67bdc0f 100644 --- a/shared/radeon_state.c +++ b/shared/radeon_state.c @@ -1441,7 +1441,8 @@ static int radeon_cp_dispatch_texture( DRMFILE filp, } if ( !buf ) { DRM_DEBUG("radeon_cp_dispatch_texture: EAGAIN\n"); - DRM_COPY_TO_USER( tex->image, image, sizeof(*image) ); + if (DRM_COPY_TO_USER( tex->image, image, sizeof(*image) )) + return DRM_ERR(EFAULT); return DRM_ERR(EAGAIN); } -- cgit v1.2.3