Closed Bug 204731 Opened 22 years ago Closed 22 years ago

Variant properties, if empty cause a crash

Categories

(Core :: XPConnect, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

VERIFIED FIXED
mozilla1.4final

People

(Reporter: dbradley, Assigned: dbradley)

References

Details

(Keywords: crash)

Attachments

(1 file)

When retrieving a variant property, if the variant is empty, it causes a crash. This is due to the fact that the code was testing the return value for "empty" to decided if it actually returned a value. Solution is to initialize the JS's return value parameter to JSVAL_VOID. Patch coming up.
Comment on attachment 122664 [details] [diff] [review] Simple one line initialization of *retval Looking for reviews for this simple one liner
Attachment #122664 - Flags: superreview?(alecf)
Attachment #122664 - Flags: review?(adamlock)
Comment on attachment 122664 [details] [diff] [review] Simple one line initialization of *retval r=adamlock
Attachment #122664 - Flags: review?(adamlock) → review+
Comment on attachment 122664 [details] [diff] [review] Simple one line initialization of *retval sr=alecf
Attachment #122664 - Flags: superreview?(alecf) → superreview+
Comment on attachment 122664 [details] [diff] [review] Simple one line initialization of *retval I'd like to get this in to 1.4, it's a one liner with little risk, and prevents a potential crash in the in the IDispatch code when properties hold an empty variant.
Attachment #122664 - Flags: approval1.4?
Status: NEW → ASSIGNED
Comment on attachment 122664 [details] [diff] [review] Simple one line initialization of *retval a=asa (on behalf of drivers) for checkin to 1.4.
Attachment #122664 - Flags: approval1.4? → approval1.4+
Patch checked in
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.4final
Checkin Verified -
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: