Last Comment Bug 671185 - Incorrect return of NS_ERROR_* codes in functions returning PRBool
: Incorrect return of NS_ERROR_* codes in functions returning PRBool
Status: RESOLVED FIXED
[inbound]
:
Product: Core
Classification: Components
Component: Rewriting and Analysis (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla8
Assigned To: Michael Wu [:mwu]
:
Mentors:
Depends on: 669808 671438
Blocks:
  Show dependency treegraph
 
Reported: 2011-07-12 22:52 PDT by Michael Wu [:mwu]
Modified: 2011-07-26 04:06 PDT (History)
6 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Fix (13.46 KB, patch)
2011-07-12 22:52 PDT, Michael Wu [:mwu]
mak77: review+
ehsan: review+
taras.mozilla: review+
cbiesinger: review+
axel: review+
khuey: review+
dholbert: review+
jaas: review+
jacob.benoit.1: review+
cpearce: review-
brian: review+
Details | Diff | Splinter Review

Description Michael Wu [:mwu] 2011-07-12 22:52:51 PDT
Created attachment 545596 [details] [diff] [review]
Fix

Problems discovered by static analysis and patched by hand.

This set of fixes touches stuff all over the place so I'm requesting reviews from many people. To be clear:

bjacob:
 content/canvas/src/WebGLContextValidate.cpp            |    2 +-

cpearce:
 content/media/ogg/nsOggCodecState.cpp                  |    2 +-

josh:
 dom/plugins/base/nsPluginStreamListenerPeer.cpp        |    3 +--

ehsan:
 editor/libeditor/base/nsSelectionState.cpp             |    2 +-

khuey:
 layout/forms/nsFileControlFrame.cpp                    |   10 +++++-----

dholbert:
 modules/libpr0n/src/VectorImage.cpp                    |    2 +-

biesi:
 netwerk/protocol/http/nsHttpChannelAuthProvider.cpp    |    9 ++++++---

pike:
 rdf/base/src/nsRDFContainerUtils.cpp                   |    9 ++++++---

bsmith:
 services/crypto/component/nsSyncJPAKE.cpp              |    2 +-

mak:
 browser/components/migration/src/nsProfileMigrator.cpp |    4 ++--
 toolkit/components/places/Helpers.h                    |   14 ++++++++++----
 toolkit/components/places/nsNavBookmarks.cpp           |    2 +-
 toolkit/components/places/nsNavHistory.cpp             |    4 ++--
 toolkit/components/places/nsNavHistoryResult.cpp       |   14 +++++++++-----

taras:
 toolkit/components/telemetry/Telemetry.cpp             |    2 +
Comment 1 Daniel Holbert [:dholbert] (mostly OOTO until Aug 9th) 2011-07-12 23:20:29 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

r=me (on the VectorImage line)  Thanks for catching these!
Comment 2 Axel Hecht 2011-07-13 03:55:42 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

Review of attachment 545596 [details] [diff] [review]:
-----------------------------------------------------------------

r=me on the RDF parts.
Comment 3 Kyle Huey [:khuey] (khuey@mozilla.com) 2011-07-13 08:48:29 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

Nice work.
Comment 4 Josh Aas 2011-07-13 08:57:45 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

Review of attachment 545596 [details] [diff] [review]:
-----------------------------------------------------------------
Comment 5 Marco Bonardo [::mak] (Away 6-20 Aug) 2011-07-13 09:00:05 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

Review of attachment 545596 [details] [diff] [review]:
-----------------------------------------------------------------

Thank you!
Comment 6 (dormant account) 2011-07-13 09:14:17 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

oops
Comment 7 Chris Pearce (:cpearce) 2011-07-13 16:00:47 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

Thanks for pointing out this error.

Unfortunately this condition is an unrecoverable error, and returning PR_FALSE from nsOggCodecState::PacketOutUntilGranulepos() doesn't enforce that. Just exclude the nsOggCodecState.cpp changes from your patch, and I'll make appropriate changes in another bug. Thanks!
Comment 8 :Ehsan Akhgari 2011-07-14 14:33:43 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

r=me on the editor hunk.
Comment 9 Michael Wu [:mwu] 2011-07-20 16:56:53 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

Switching reviewers - bjacob -> joe on the WebGLContextValidate.cpp part.
Comment 10 Benoit Jacob [:bjacob] (mostly away) 2011-07-24 21:32:13 PDT
Comment on attachment 545596 [details] [diff] [review]
Fix

r+ for the WebGL part (back from vacation). Thanks for that.
Comment 11 Michael Wu [:mwu] 2011-07-25 22:13:27 PDT
Thanks for all the reviews.

http://hg.mozilla.org/integration/mozilla-inbound/rev/7a21ce9c4482
Comment 12 Marco Bonardo [::mak] (Away 6-20 Aug) 2011-07-26 04:06:10 PDT
http://hg.mozilla.org/mozilla-central/rev/7a21ce9c4482

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