Closed Bug 280889 Opened 20 years ago Closed 20 years ago

cursor can be used uninitialized in nsEventStateManager::UpdateCursor

Categories

(Core :: Layout, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: dveditz, Assigned: dveditz)

References

(Blocks 1 open bug)

Details

(Keywords: coverity, Whiteboard: Coverity UNINIT)

Attachments

(1 file, 1 obsolete file)

If aTargetFrame is null then cursor can be used uninitialized in some cases in
nsEventStateManager::UpdateCursor.
Attached patch initialize cursor (obsolete) — Splinter Review
Caught using /RTCu windows compiler option, uninitialized use seen in action.
If aTargetFrame is null we don't try to set the real cursor to this value, but
it is used in a couple comparisons still.
Attachment #173236 - Flags: review?(bzbarsky)
Comment on attachment 173236 [details] [diff] [review]
initialize cursor

Shouldn't that be !CheckDisabled ?
Attached patch correct versionSplinter Review
Of course it should be (I blame the codeine). Thanks!
Attachment #173236 - Attachment is obsolete: true
Attachment #173236 - Flags: review?(bzbarsky)
Attachment #173245 - Flags: superreview?(bzbarsky)
Attachment #173245 - Flags: review?(bzbarsky)
Comment on attachment 173245 [details] [diff] [review]
correct version

r+sr=bzbarsky
Attachment #173245 - Flags: superreview?(bzbarsky)
Attachment #173245 - Flags: superreview+
Attachment #173245 - Flags: review?(bzbarsky)
Attachment #173245 - Flags: review+
Also found by Coverity
Whiteboard: Coverity UNINIT
Checked into trunk
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Keywords: coverity
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: