NSC_CopyObject crashes if pk11_CopyObject fails

RESOLVED FIXED in 3.4

Status

P2
normal
RESOLVED FIXED
17 years ago
17 years ago

People

(Reporter: jamie-bugzilla, Assigned: jamie-bugzilla)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Assignee)

Description

17 years ago
If pk11_CopyObject fails in NSC_CopyObject, we free the object but then continue
with the function. We try to use the object we just freed and crash.  We should
probably return or jump to the end of the function.
(Assignee)

Comment 1

17 years ago
Created attachment 73601 [details] [diff] [review]
proposed patch

Jump to the end of the function if pk11_CopyObject fails.
(Assignee)

Comment 2

17 years ago
I don't think this needs to get fixed for NSS 3.4 because it won't get exercized  .

Comment 3

17 years ago
Created attachment 73609 [details] [diff] [review]
proposed patch 2

In keeping with the current style of error handling in that
function, I suggest this patch instead.  We should just return
crv directly.

Comment 4

17 years ago
I checked in patch #2.
Status: NEW → RESOLVED
Last Resolved: 17 years ago
Priority: -- → P2
Resolution: --- → FIXED
Target Milestone: --- → 3.4

Updated

17 years ago
Blocks: 131513
You need to log in before you can comment on or make changes to this bug.