Last Comment Bug 210834 - Bogus comparison in nsCSSParserImpl::ParseURL
: Bogus comparison in nsCSSParserImpl::ParseURL
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: CSS Parsing and Computation (show other bugs)
: Trunk
: All All
: -- normal (vote)
: ---
Assigned To: jag (Peter Annema)
: Hixie (not reading bugmail)
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2003-06-26 16:45 PDT by jag (Peter Annema)
Modified: 2003-07-13 15:25 PDT (History)
4 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Fix comparison, clean up code a little (1.26 KB, patch)
2003-06-26 16:47 PDT, jag (Peter Annema)
jst: review+
bzbarsky: superreview+
Details | Diff | Splinter Review

Description jag (Peter Annema) 2003-06-26 16:45:32 PDT
 
Comment 1 jag (Peter Annema) 2003-06-26 16:47:11 PDT
Created attachment 126593 [details] [diff] [review]
Fix comparison, clean up code a little
Comment 2 jag (Peter Annema) 2003-06-26 16:48:02 PDT
See bug 98786.
Comment 3 jag (Peter Annema) 2003-06-26 16:51:11 PDT
Comment on attachment 126593 [details] [diff] [review]
Fix comparison, clean up code a little

Alternatively I guess I could say something like |if (absURL.IsEmpty()) absURL
= tk->mIdent;| instead of this NS_FAILED(rv) trick. Preference?
Comment 4 Johnny Stenback (:jst, jst@mozilla.com) 2003-06-26 19:13:44 PDT
Comment on attachment 126593 [details] [diff] [review]
Fix comparison, clean up code a little

Yeah, IMO using absURL.IsEmpty() in stead of rv here would be cleaner.

r=jst either way.
Comment 5 Boris Zbarsky [:bz] (still a bit busy) 2003-06-28 19:09:37 PDT
Comment on attachment 126593 [details] [diff] [review]
Fix comparison, clean up code a little

sr=me; I think I prefer the rv check.
Comment 6 jag (Peter Annema) 2003-07-08 04:51:03 PDT
I've gone with the rv check (though I should be able to depend on absURL not
being touched if NS_FAILED(rv)).
Comment 7 Boris Zbarsky [:bz] (still a bit busy) 2003-07-08 10:34:57 PDT
> though I should be able to depend on absURL not being touched

Necko functions explicitly do not guarantee this; just ask darin.
Comment 8 jag (Peter Annema) 2003-07-13 15:25:01 PDT
Cool, so check on rv it is then.

Note You need to log in before you can comment on or make changes to this bug.