From e647799f6a2f7f747c9f55d9f0ce08dcdfbd53f4 Mon Sep 17 00:00:00 2001 From: tsepez Date: Thu, 5 Jan 2017 12:57:00 -0800 Subject: Properly ref-count CFGAS_GEFont with CFX_RetainPtr. We worry about cyclical references, but no leaks found. Review-Url: https://codereview.chromium.org/2609423003 --- xfa/fwl/cfwl_barcode.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'xfa/fwl/cfwl_barcode.cpp') diff --git a/xfa/fwl/cfwl_barcode.cpp b/xfa/fwl/cfwl_barcode.cpp index 8b05927223..0412b86958 100644 --- a/xfa/fwl/cfwl_barcode.cpp +++ b/xfa/fwl/cfwl_barcode.cpp @@ -169,8 +169,7 @@ void CFWL_Barcode::GenerateBarcodeImageCache() { if (pTheme) { CFWL_ThemePart part; part.m_pWidget = this; - - if (CFGAS_GEFont* pFont = pTheme->GetFont(&part)) { + if (CFX_RetainPtr pFont = pTheme->GetFont(&part)) { if (CFX_Font* pCXFont = pFont->GetDevFont()) m_pBarcodeEngine->SetFont(pCXFont); } -- cgit v1.2.3