Make gwbuf_alloc_and_load const correct.

This commit is contained in:
Johan Wikman
2016-09-07 12:31:26 +03:00
parent 58a8bdd4ab
commit 5360918344
2 changed files with 2 additions and 2 deletions

View File

@ -143,7 +143,7 @@ retblock:
* be allocated. * be allocated.
*/ */
GWBUF * GWBUF *
gwbuf_alloc_and_load(unsigned int size, void *data) gwbuf_alloc_and_load(unsigned int size, const void *data)
{ {
GWBUF *rval; GWBUF *rval;
if ((rval = gwbuf_alloc(size)) != NULL) if ((rval = gwbuf_alloc(size)) != NULL)

View File

@ -183,7 +183,7 @@ typedef struct gwbuf
* Function prototypes for the API to maniplate the buffers * Function prototypes for the API to maniplate the buffers
*/ */
extern GWBUF *gwbuf_alloc(unsigned int size); extern GWBUF *gwbuf_alloc(unsigned int size);
extern GWBUF *gwbuf_alloc_and_load(unsigned int size, void *data); extern GWBUF *gwbuf_alloc_and_load(unsigned int size, const void *data);
extern void gwbuf_free(GWBUF *buf); extern void gwbuf_free(GWBUF *buf);
extern GWBUF *gwbuf_clone(GWBUF *buf); extern GWBUF *gwbuf_clone(GWBUF *buf);
extern GWBUF *gwbuf_append(GWBUF *head, GWBUF *tail); extern GWBUF *gwbuf_append(GWBUF *head, GWBUF *tail);