зеркало из https://github.com/mozilla/pjs.git
Be sure to initialize out-param no matter what. b=127360 r=aaronl sr=brendan a=asa (drivers)
This commit is contained in:
Родитель
a29324d20f
Коммит
c58b010410
|
@ -600,10 +600,11 @@ FrameManager::GetCanvasFrame(nsIPresContext* aPresContext, nsIFrame** aCanvasFra
|
|||
NS_IMETHODIMP
|
||||
FrameManager::GetPrimaryFrameFor(nsIContent* aContent, nsIFrame** aResult)
|
||||
{
|
||||
NS_ASSERTION(aResult, "null out-param not supported");
|
||||
*aResult = nsnull; // initialize out param (before possibly returning due to null args/members)
|
||||
|
||||
NS_ENSURE_TRUE(mPresShell, NS_ERROR_NOT_AVAILABLE);
|
||||
NS_ENSURE_ARG_POINTER(aResult);
|
||||
NS_ENSURE_ARG_POINTER(aContent);
|
||||
*aResult = nsnull; // initialize out param
|
||||
|
||||
if (mIsDestroyingFrames) {
|
||||
#ifdef DEBUG
|
||||
|
|
|
@ -600,10 +600,11 @@ FrameManager::GetCanvasFrame(nsIPresContext* aPresContext, nsIFrame** aCanvasFra
|
|||
NS_IMETHODIMP
|
||||
FrameManager::GetPrimaryFrameFor(nsIContent* aContent, nsIFrame** aResult)
|
||||
{
|
||||
NS_ASSERTION(aResult, "null out-param not supported");
|
||||
*aResult = nsnull; // initialize out param (before possibly returning due to null args/members)
|
||||
|
||||
NS_ENSURE_TRUE(mPresShell, NS_ERROR_NOT_AVAILABLE);
|
||||
NS_ENSURE_ARG_POINTER(aResult);
|
||||
NS_ENSURE_ARG_POINTER(aContent);
|
||||
*aResult = nsnull; // initialize out param
|
||||
|
||||
if (mIsDestroyingFrames) {
|
||||
#ifdef DEBUG
|
||||
|
|
Загрузка…
Ссылка в новой задаче