diff options
author | Michal Krol <[email protected]> | 2009-09-15 12:00:27 +0100 |
---|---|---|
committer | Michal Krol <[email protected]> | 2009-09-15 12:00:27 +0100 |
commit | 7aee53002c25369364f5d26aeb63d6c467f77c49 (patch) | |
tree | b98fe7f775e1263575716030fdf521adbc743040 /src/gallium/include | |
parent | 750c6cae3d6f5b24c0c51537a5717894675645c6 (diff) |
gallium: Fix pointer type casts.
Diffstat (limited to 'src/gallium/include')
-rw-r--r-- | src/gallium/include/pipe/p_inlines.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gallium/include/pipe/p_inlines.h b/src/gallium/include/pipe/p_inlines.h index 4f0a7a4ef63..aa757e7bda1 100644 --- a/src/gallium/include/pipe/p_inlines.h +++ b/src/gallium/include/pipe/p_inlines.h @@ -118,7 +118,7 @@ pipe_buffer_write(struct pipe_screen *screen, unsigned offset, unsigned size, const void *data) { - uint8_t *map; + void *map; assert(offset < buf->size); assert(offset + size <= buf->size); @@ -129,7 +129,7 @@ pipe_buffer_write(struct pipe_screen *screen, PIPE_BUFFER_USAGE_FLUSH_EXPLICIT); assert(map); if(map) { - memcpy(map + offset, data, size); + memcpy((uint8_t *)map + offset, data, size); pipe_buffer_flush_mapped_range(screen, buf, offset, size); pipe_buffer_unmap(screen, buf); } @@ -141,7 +141,7 @@ pipe_buffer_read(struct pipe_screen *screen, unsigned offset, unsigned size, void *data) { - uint8_t *map; + void *map; assert(offset < buf->size); assert(offset + size <= buf->size); @@ -150,7 +150,7 @@ pipe_buffer_read(struct pipe_screen *screen, map = pipe_buffer_map_range(screen, buf, offset, size, PIPE_BUFFER_USAGE_CPU_READ); assert(map); if(map) { - memcpy(data, map + offset, size); + memcpy(data, (const uint8_t *)map + offset, size); pipe_buffer_unmap(screen, buf); } } |