mirror of
https://github.com/netsurf-browser/netsurf
synced 2024-11-25 07:49:38 +03:00
js: image data: Avoid int overflow before size_t conversion
This commit is contained in:
parent
c50f4bab09
commit
cb5d63768c
@ -39,6 +39,6 @@ getter ImageData::data()
|
||||
%{
|
||||
duk_push_this(ctx);
|
||||
duk_get_prop_string(ctx, -1, MAGIC(DATA));
|
||||
duk_push_buffer_object(ctx, -1, 0, priv->width * priv->height * 4, DUK_BUFOBJ_UINT8CLAMPEDARRAY);
|
||||
duk_push_buffer_object(ctx, -1, 0, priv->width * priv->height * 4llu, DUK_BUFOBJ_UINT8CLAMPEDARRAY);
|
||||
return 1;
|
||||
%}
|
||||
|
Loading…
Reference in New Issue
Block a user