Closed
Bug 195731
Opened 22 years ago
Closed 21 years ago
Compiler warning in security/manager/ssl/src/nsPKCS12Blob.cpp
Categories
(Core Graveyard :: Security: UI, defect)
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 194240
People
(Reporter: tenthumbs, Assigned: ssaux)
Details
Gcc says
nsPKCS12Blob.cpp:538: warning: \
comparison of unsigned expression < 0 is always false
The code is
529 PRUint32 amount;
...
538 if (amount < 0) {
539 fileStream.close();
540 return NS_ERROR_FAILURE;
541 }
so the error block is unreachable and gcc eliminates it.
Comment 1•22 years ago
|
||
Over to something like the right product....
Assignee: mstoltz → ssaux
Severity: normal → major
Component: Security: General → Client Library
Product: Browser → PSM
QA Contact: carosendahl → junruh
Version: Trunk → 2.4
Updated•21 years ago
|
Blocks: buildwarning
Comment 2•21 years ago
|
||
Fix included in bug 194240 attachment 117024 [details] [diff] [review]
{
while (PR_TRUE) {
- amount = fileStream.read(buf, PIP_PKCS12_BUFFER_SIZE);
- if (amount < 0) {
- fileStream.close();
- return NS_ERROR_FAILURE;
+ rv = fileStream->Read(buf, PIP_PKCS12_BUFFER_SIZE, &amount);
+ if (NS_FAILED(rv)) {
+ return rv;
}
}
which was v1.36.
*** This bug has been marked as a duplicate of 194240 ***
No longer blocks: buildwarning
Status: NEW → RESOLVED
Closed: 21 years ago
OS: Linux → All
Hardware: PC → All
Resolution: --- → DUPLICATE
Updated•8 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•