mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-04 20:00:11 +01:00
util: silence warnings for third REALLOC argument
Our fallback realloc path requires an old_size argument, but the posix varient doesn't need this. Add some code to avoid gcc unused variable warnings for this extra argument.
This commit is contained in:
parent
b1d82f1f19
commit
120e76866b
1 changed files with 7 additions and 1 deletions
|
|
@ -100,8 +100,14 @@ ExFreePool(void *P);
|
|||
#define MALLOC( SIZE ) malloc( SIZE )
|
||||
#define CALLOC( COUNT, SIZE ) calloc( COUNT, SIZE )
|
||||
#define FREE( PTR ) free( PTR )
|
||||
#define REALLOC( OLDPTR, OLDSIZE, NEWSIZE ) realloc( OLDPTR, NEWSIZE )
|
||||
|
||||
static INLINE void *
|
||||
_REALLOC( void *old_ptr, unsigned old_size, unsigned new_size )
|
||||
{
|
||||
(void) old_size;
|
||||
return realloc(old_ptr, new_size);
|
||||
}
|
||||
#define REALLOC( a, b, c ) _REALLOC( a, b, c )
|
||||
#endif
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue