Closed
Bug 194227
Opened 22 years ago
Closed 22 years ago
[AxPlugin] Events parameters are sent in the wrong order
Categories
(Core Graveyard :: Embedding: APIs, defect)
Tracking
(Not tracked)
VERIFIED
FIXED
People
(Reporter: adamlock, Assigned: adamlock)
References
Details
Attachments
(1 file)
884 bytes,
patch
|
dbradley
:
review+
brendan
:
superreview+
asa
:
approval1.3+
|
Details | Diff | Splinter Review |
Events are fired with their parameters in the reverse order. The mistake crept in during checkin of bug 178542. http://bonsai.mozilla.org/cvsview2.cgi?diff_mode=context&whitespace_mode=show&file=XPConnect.cpp&root=/cvsroot&subdir=mozilla/embedding/browser/activex/src/plugin&command=DIFF_FRAMESET&rev1=1.17&rev2=1.18 Patch follows to correct the issue
Simple patch grabs disp args in reverse order. Proper ordering got lost in the churn of the event sink rewrite. The old version got it right, the new one didn't.
Comment 2•22 years ago
|
||
Where are actual arguments being reversed? /be
In code like this: <script for="someObject" event="FSCommand(command, args)"> </script> Instead of (command, args) it is sent as (args, command) because the plugin code that processes the args from the control is not putting them in the right order. The reason is that IDispatch::Invoke sends its arguments in an array with the args in reverse order, e.g. pDispParams->rgvarg[0] = arg3; pDispParams->rgvarg[1] = arg2; pDispParams->rgvarg[2] = arg1; The plugin used to have some code to put them in the proper order, but unfortunately it was overlooked during a big code merge. This small patch reinstates the correct behaviour.
Comment 4•22 years ago
|
||
Comment on attachment 115015 [details] [diff] [review] Patch r=dbradley
Attachment #115015 -
Flags: review+
Comment on attachment 115015 [details] [diff] [review] Patch Brendan, can you give this an sr? Thanks
Attachment #115015 -
Flags: superreview?(brendan)
Comment 6•22 years ago
|
||
Comment on attachment 115015 [details] [diff] [review] Patch I was thrown by the comment, cuz it seemed to leave open the possibility that the bizarre reason was not by design of IDispatch. Maybe clarify it to say "arguments are listed backwards, intentionally, in rgvarg." sr=brendan@mozilla.org in any event. /be
Attachment #115015 -
Flags: superreview?(brendan) → superreview+
Comment on attachment 115015 [details] [diff] [review] Patch Requesting 1.3 apporval. ActiveX specific, low risk, obvious fix for regression.
Attachment #115015 -
Flags: approval1.3?
Comment 9•22 years ago
|
||
Comment on attachment 115015 [details] [diff] [review] Patch a=asa (on behalf of drivers) for checkin to 1.3
Attachment #115015 -
Flags: approval1.3? → approval1.3+
Assignee | ||
Comment 10•22 years ago
|
||
Fix is checked in
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Updated•5 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•