pipebuffer: Fix buffer overflow.

This commit is contained in:
José Fonseca 2008-11-25 14:01:40 +09:00
parent f8870af44b
commit 55839ae064

View file

@ -182,7 +182,7 @@ pb_validate_create()
return NULL;
vl->size = PB_VALIDATE_INITIAL_SIZE;
vl->entries = (struct pb_validate_entry *)CALLOC(vl->size, sizeof(struct pb_buffer *));
vl->entries = (struct pb_validate_entry *)CALLOC(vl->size, sizeof(struct pb_validate_entry));
if(!vl->entries) {
FREE(vl);
return NULL;