/* Grow the packet buffer to the specified size.  */
static int grow_buffer(pcap_t *p, u_int bufsize)
/* Grow the packet buffer to the specified size.  */
static int grow_buffer(pcap_t *p, u_int bufsize)
{
	void *bigger_buffer;
	bigger_buffer = realloc(p->buffer, bufsize);
	if (bigger_buffer == NULL) {
		pcap_snprintf(p->errbuf, PCAP_ERRBUF_SIZE, "out of memory");
		return (0);
	}
	p->buffer = bigger_buffer;
	p->bufsize = bufsize;
	return (1);
}