From 4912cad20d302594d04372f06a2006da581ed862 Mon Sep 17 00:00:00 2001 From: Michael Layzell Date: Mon, 25 May 2015 11:32:00 -0400 Subject: [PATCH] Bug 1168176 - Mark gfxFontShaper::mFont as MOZ_NON_OWNING_REF. r=jtd --- gfx/thebes/gfxFont.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gfx/thebes/gfxFont.h b/gfx/thebes/gfxFont.h index a31d23360b1..0ce99f99432 100644 --- a/gfx/thebes/gfxFont.h +++ b/gfx/thebes/gfxFont.h @@ -649,8 +649,10 @@ public: void* aHandleFeatureData); protected: - // the font this shaper is working with - gfxFont * mFont; + // the font this shaper is working with. The font owns a nsAutoPtr reference + // to this object, and will destroy it before it dies. Thus, mFont will always + // be valid. + gfxFont* MOZ_NON_OWNING_REF mFont; };