Alocate jsclass_document_priv size.

This commit is contained in:
Michael Drake 2012-10-05 15:06:32 +01:00
parent 75df8b9d4a
commit 3c4f4ca461

View File

@ -228,7 +228,7 @@ JSObject *jsapi_new_document(JSContext *cx, JSObject *parent, struct html_conten
JSObject *jsdocument;
struct jsclass_document_priv *document;
document = malloc(sizeof(document));
document = malloc(sizeof(*document));
if (document == NULL) {
return NULL;
}