On 2014/03/06 7:14, Alon Zakai wrote:
> Ok, looks like it is accessing internal fields on the XDisplay object.
Yes it is.
> We have very minimalistic xlib support, just enough to run those
> tests, and that does not include having proper values in those fields.
> To fix this we would need to do a proper port of xlib from source,
> most likely, not sure if anyone wants to do that.
Looking at the JS emulation code, which I should have looked at before
claiming a compiler issue, the problem is obvious. XOpenDisplay returns
1 which is then used as the base address by the DefaultRootWindow macro
to de-reference the 32-bit root-window value triggering the SAFE_HEAP
exception.
For now I have hacked up my copy of esUtil.c. A fix to avoid this issue
and any other potential issues without porting xlib is to make the JS
XOpenDisplay return the "address" of an aligned chunk of memory the size
of an _XPrivDisplay structure. I don't know how to do that, otherwise I
would submit a pull request.
Regards
-Mark
--
注意:この電子メールには、株式会社エイチアイの機密情報が含まれている場合
が有ります。正式なメール受信者では無い場合はメール複製、 再配信または情
報の使用を固く禁じております。エラー、手違いでこのメールを受け取られまし
たら削除を行い配信者にご連絡をお願いいたし ます.
NOTE: This electronic mail message may contain confidential and
privileged information from HI Corporation. If you are not the intended
recipient, any disclosure, photocopying, distribution or use of the
contents of the received information is prohibited. If you have received
this e-mail in error, please notify the sender immediately and
permanently delete this message and all related copies.
--
You received this message because you are subscribed to the Google Groups
"emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.