Closed
Bug 620390
Opened 14 years ago
Closed 14 years ago
useless null check of host = flat.get() in nsStandardURL::SetHost
Categories
(Core :: Networking, enhancement)
Core
Networking
Tracking
()
RESOLVED
FIXED
mozilla5
People
(Reporter: timeless, Assigned: timeless)
References
(Blocks 1 open bug)
Details
(Keywords: coverity)
Attachments
(1 file, 1 obsolete file)
(deleted),
patch
|
Biesinger
:
review+
|
Details | Diff | Splinter Review |
1415 nsStandardURL::SetHost(const nsACString &input)
1420 const char *host = flat.get();
null safe:
1431 if (host && strlen(host) < flat.Length())
1432 return NS_ERROR_MALFORMED_URI; // found embedded null
not null safe:
1436 if (strchr(host, ' '))
1437 return NS_ERROR_MALFORMED_URI;
null safe:
1442 if (!(host && *host)) {
Assignee: nobody → timeless
Status: NEW → ASSIGNED
Attachment #498879 -
Flags: review?(cbiesinger)
Attachment #498879 -
Flags: approval2.0?
Comment 2•14 years ago
|
||
Comment on attachment 498879 [details] [diff] [review]
patch
flat.get() never returns NULL
Attachment #498879 -
Flags: review?(cbiesinger) → review-
Severity: critical → enhancement
Keywords: crash
Summary: crash [@ nsStandardURL::SetHost] when flat.get() returns null → useless null check of host = flat.get() in nsStandardURL::SetHost
Comment 3•14 years ago
|
||
Comment on attachment 498879 [details] [diff] [review]
patch
Mass minusing patch approval that don't have high return. Please renominate if this is more important for 2.0 than it appears.
Attachment #498879 -
Flags: approval2.0? → approval2.0-
Attachment #498879 -
Attachment is obsolete: true
Attachment #513053 -
Flags: review?(cbiesinger)
Comment 5•14 years ago
|
||
Comment on attachment 513053 [details] [diff] [review]
remove null checks
_please_ diff with more context
Attachment #513053 -
Flags: review?(cbiesinger) → review+
Comment 6•14 years ago
|
||
Whiteboard: fixed-in-cedar
Comment 7•14 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Whiteboard: fixed-in-cedar
Target Milestone: --- → mozilla2.2
Updated•6 years ago
|
Blocks: coverity-analysis
You need to log in
before you can comment on or make changes to this bug.
Description
•