diff options
Diffstat (limited to 'src/mesa/pipe/cell/ppu/cell_state_sampler.c')
-rw-r--r-- | src/mesa/pipe/cell/ppu/cell_state_sampler.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/mesa/pipe/cell/ppu/cell_state_sampler.c b/src/mesa/pipe/cell/ppu/cell_state_sampler.c index 317f7603bb..ade6cc8338 100644 --- a/src/mesa/pipe/cell/ppu/cell_state_sampler.c +++ b/src/mesa/pipe/cell/ppu/cell_state_sampler.c @@ -40,9 +40,7 @@ void * cell_create_sampler_state(struct pipe_context *pipe, const struct pipe_sampler_state *sampler) { - struct pipe_sampler_state *state = MALLOC( sizeof(struct pipe_sampler_state) ); - memcpy(state, sampler, sizeof(struct pipe_sampler_state)); - return state; + return mem_dup(sampler, sizeof(*sampler)); } void |