Closed
Bug 265708
Opened 21 years ago
Closed 21 years ago
count should be CK_ULONG in SECMOD_UpdateSlotList
Categories
(NSS :: Libraries, defect, P1)
Tracking
(Not tracked)
RESOLVED
FIXED
3.9.4
People
(Reporter: julien.pierre, Assigned: julien.pierre)
Details
Attachments
(1 file)
640 bytes,
patch
|
wtc
:
review+
|
Details | Diff | Splinter Review |
The compiler gives the following warnings on most platforms :
"pk11util.c", line 869: warning: argument #3 is incompatible with prototype:
prototype: pointer to unsigned long : "unknown", line 0
argument : pointer to int
"pk11util.c", line 892: warning: argument #3 is incompatible with prototype:
prototype: pointer to unsigned long : "unknown", line 0
argument : pointer to int
In the LP64 model, this will cause "count" to hold the wrong count from
C_GetSlotList, because CK_ULONG and int are different sizes.
Assignee | ||
Updated•21 years ago
|
Priority: -- → P1
Target Milestone: --- → 3.9.4
Assignee | ||
Comment 1•21 years ago
|
||
Assignee | ||
Updated•21 years ago
|
Keywords: sun-orion3
Assignee | ||
Comment 2•21 years ago
|
||
Checked in the patch to NSS_3_9_BRANCH :
Checking in pk11util.c;
/cvsroot/mozilla/security/nss/lib/pk11wrap/pk11util.c,v <-- pk11util.c
new revision: 1.41.16.3; previous revision: 1.41.16.2
done
and the tip
Checking in pk11util.c;
/cvsroot/mozilla/security/nss/lib/pk11wrap/pk11util.c,v <-- pk11util.c
new revision: 1.45; previous revision: 1.44
done
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
Comment 3•21 years ago
|
||
Comment on attachment 163094 [details] [diff] [review]
change count variable type to CK_ULONG
This fix is needed for the code to be
correct on LP64 platforms, but because
'count' changes from signed to unsigned
and on some platforms from 32-bit to
64-bit, the fix may generate new compiler
warnings (signed/unsigned comparison and
integral type size).
Attachment #163094 -
Flags: review+
Comment 4•21 years ago
|
||
The function that had the bug, SECMOD_UpdateSlotList,
was a new function added in NSS 3.9.3. So this bug
was introduced in NSS 3.9.3.
You need to log in
before you can comment on or make changes to this bug.
Description
•