Pacify GCC 9 -Wredundant-decls
* src/gmalloc.c (_fraghead) [!HYBRID_MALLOC]: Make it static in this case, too. This avoids having both ‘extern struct list _fraghead[];’ and ‘static struct list _fraghead[BLOCKLOG];’, which GCC 9 complains about.
This commit is contained in:
parent
7871c3dc9f
commit
4b24b0185d
1 changed files with 1 additions and 8 deletions
|
@ -182,7 +182,7 @@ struct list
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Free list headers for each fragment size. */
|
/* Free list headers for each fragment size. */
|
||||||
extern struct list _fraghead[];
|
static struct list _fraghead[BLOCKLOG];
|
||||||
|
|
||||||
/* List of blocks allocated with aligned_alloc and friends. */
|
/* List of blocks allocated with aligned_alloc and friends. */
|
||||||
struct alignlist
|
struct alignlist
|
||||||
|
@ -339,9 +339,6 @@ size_t _heapindex;
|
||||||
/* Limit of valid info table indices. */
|
/* Limit of valid info table indices. */
|
||||||
size_t _heaplimit;
|
size_t _heaplimit;
|
||||||
|
|
||||||
/* Free lists for each fragment size. */
|
|
||||||
struct list _fraghead[BLOCKLOG];
|
|
||||||
|
|
||||||
/* Instrumentation. */
|
/* Instrumentation. */
|
||||||
size_t _chunks_used;
|
size_t _chunks_used;
|
||||||
size_t _bytes_used;
|
size_t _bytes_used;
|
||||||
|
@ -351,10 +348,6 @@ size_t _bytes_free;
|
||||||
/* Are you experienced? */
|
/* Are you experienced? */
|
||||||
int __malloc_initialized;
|
int __malloc_initialized;
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
static struct list _fraghead[BLOCKLOG];
|
|
||||||
|
|
||||||
#endif /* HYBRID_MALLOC */
|
#endif /* HYBRID_MALLOC */
|
||||||
|
|
||||||
/* Number of extra blocks to get each time we ask for more core.
|
/* Number of extra blocks to get each time we ask for more core.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue