mshtml: Adjusted some incorrect sizeofs (Coverity).

This commit is contained in:
Marcus Meissner 2011-10-18 05:05:51 +02:00 committed by Alexandre Julliard
parent cd51c797f3
commit 59fc063a34
1 changed files with 3 additions and 3 deletions

View File

@ -61,7 +61,7 @@ static void elem_vector_add(elem_vector_t *buf, HTMLElement *elem)
{
if(buf->len == buf->size) {
buf->size <<= 1;
buf->buf = heap_realloc(buf->buf, buf->size*sizeof(HTMLElement**));
buf->buf = heap_realloc(buf->buf, buf->size*sizeof(HTMLElement*));
}
buf->buf[buf->len++] = elem;
@ -73,7 +73,7 @@ static void elem_vector_normalize(elem_vector_t *buf)
heap_free(buf->buf);
buf->buf = NULL;
}else if(buf->size > buf->len) {
buf->buf = heap_realloc(buf->buf, buf->len*sizeof(HTMLElement**));
buf->buf = heap_realloc(buf->buf, buf->len*sizeof(HTMLElement*));
}
buf->size = buf->len;
@ -530,7 +530,7 @@ IHTMLElementCollection *create_all_collection(HTMLDOMNode *node, BOOL include_ro
{
elem_vector_t buf = {NULL, 0, 8};
buf.buf = heap_alloc(buf.size*sizeof(HTMLElement**));
buf.buf = heap_alloc(buf.size*sizeof(HTMLElement*));
if(include_root)
elem_vector_add(&buf, elem_from_HTMLDOMNode(node));