mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 08:58:02 +02:00
svga: rewrite svga_buffer() cast wrapper
To make it symmetric with the svga_texture() cast wrapper. Reviewed-by: Neha Bhende <bhenden@vmware.com>
This commit is contained in:
parent
c72dcd9a71
commit
e206f67261
1 changed files with 4 additions and 6 deletions
|
|
@ -196,13 +196,11 @@ struct svga_buffer
|
|||
|
||||
|
||||
static inline struct svga_buffer *
|
||||
svga_buffer(struct pipe_resource *buffer)
|
||||
svga_buffer(struct pipe_resource *resource)
|
||||
{
|
||||
if (buffer) {
|
||||
assert(((struct svga_buffer *)buffer)->b.vtbl == &svga_buffer_vtbl);
|
||||
return (struct svga_buffer *)buffer;
|
||||
}
|
||||
return NULL;
|
||||
struct svga_buffer *buf = (struct svga_buffer *) resource;
|
||||
assert(buf == NULL || buf->b.vtbl == &svga_buffer_vtbl);
|
||||
return buf;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue