Last Comment Bug 660681 - LeaveFunction doesn't check outer_ale enough for OOM
: LeaveFunction doesn't check outer_ale enough for OOM
Status: RESOLVED FIXED
[fixed-in-tracemonkey]
:
Product: Core
Classification: Components
Component: JavaScript Engine (show other bugs)
: unspecified
: x86 Mac OS X
: -- normal (vote)
: ---
Assigned To: Paul Biggar
:
Mentors:
Depends on:
Blocks: 624094
  Show dependency treegraph
 
Reported: 2011-05-30 11:48 PDT by Paul Biggar
Modified: 2011-06-13 10:59 PDT (History)
2 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
fix (1.25 KB, patch)
2011-05-30 11:48 PDT, Paul Biggar
no flags Details | Diff | Review
move the check (1.31 KB, patch)
2011-06-06 10:25 PDT, Paul Biggar
jimb: review+
Details | Diff | Review

Description Paul Biggar 2011-05-30 11:48:21 PDT
Created attachment 536135 [details] [diff] [review]
fix

In LeaveFunction, outer_ale is checked a number of times, but the last one is not checked for OOM. Simple fix.
Comment 1 Jim Blandy :jimb 2011-06-06 07:26:20 PDT
Comment on attachment 536135 [details] [diff] [review]
fix

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

::: js/src/jsparse.cpp
@@ +2839,5 @@
>                   */
>                  outer_ale = MakePlaceholder(dn, tc);
>              }
>  
> +            if (!outer_ale)

Shouldn't this be just after the call to MakePlaceHolder? These checks should go right after the call that could fail.
Comment 2 Paul Biggar 2011-06-06 10:25:43 PDT
Created attachment 537582 [details] [diff] [review]
move the check
Comment 4 Chris Leary [:cdleary] (not checking bugmail) 2011-06-13 10:59:28 PDT
cdleary-bot mozilla-central merge info:
http://hg.mozilla.org/mozilla-central/rev/cc612a118e7c

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