Bug#669905: Analysis

Jurij Smakov jurij at wooyd.org
Mon Apr 23 09:02:24 UTC 2012


Hi,

It's pretty clear why the unaligned access happens. At 
js/xpconnect/src/xpcprivate.h:1335 a new XPCCallContext object is 
created using

            mCcxToDestroy = mCcx =
                new (mData) XPCCallContext(mCallerLanguage, mCx,
                                           mCallBeginRequest == CALL_BEGINREQUEST,
                                           mObj,
                                           mFlattenedJSObject, mWrapper,
                                           mTearOff);

Memory for the object (pointed to by mData) is allocated at line 1363 
using

    char mData[sizeof(XPCCallContext)];

Char array has no alignment requirements. 

Best regards,
-- 
Jurij Smakov                                           jurij at wooyd.org
Key: http://www.wooyd.org/pgpkey/                      KeyID: C99E03CC





More information about the pkg-mozilla-maintainers mailing list