Last Comment Bug 680037 - possible use of uninitialized values in nsFontFaceLoader::LoadTimerCallback
: possible use of uninitialized values in nsFontFaceLoader::LoadTimerCallback
Status: RESOLVED FIXED
: valgrind
Product: Core
Classification: Components
Component: Layout: Text (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla9
Assigned To: Jonathan Kew (:jfkthame)
:
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-08-18 03:10 PDT by Jonathan Kew (:jfkthame)
Modified: 2011-08-23 08:57 PDT (History)
1 user (show)
mounir: in‑testsuite-
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
patch v1 - check calls for failure before using the results (1.32 KB, patch)
2011-08-18 03:10 PDT, Jonathan Kew (:jfkthame)
jd.bugzilla: review+
Details | Diff | Splinter Review

Description Jonathan Kew (:jfkthame) 2011-08-18 03:10:06 PDT
Created attachment 554022 [details] [diff] [review]
patch v1 - check calls for failure before using the results

In nsFontFaceLoader::LoadTimerCallback, we don't check the GetContentLength and GetNumBytesRead calls for success, which means that we may end up using uninitialized values (in the event one of these calls failed) when testing how far the download has progressed.

While this isn't a critical problem - the worst-case result is that we suppress fallback rendering for an extra 50% delay period - we should fix it to ensure more consistent behavior, as well as to avoid Valgrind complaints.
Comment 1 Jonathan Kew (:jfkthame) 2011-08-23 05:39:07 PDT
http://hg.mozilla.org/integration/mozilla-inbound/rev/d051bc49c304
Comment 2 Mounir Lamouri (:mounir) 2011-08-23 08:57:40 PDT
http://hg.mozilla.org/mozilla-central/rev/d051bc49c304

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