From 25694831670ef6172b1b9b71359a6c192e26da20 Mon Sep 17 00:00:00 2001 From: Tom Sepez Date: Fri, 21 Apr 2017 15:42:49 -0700 Subject: Use unique_ptr in CFX_FolderFontInfo::m_FontList Avoid a string duplication along the way. Change-Id: I866c34ad1afb20b9578aeb7cabeb8a185674c884 Reviewed-on: https://pdfium-review.googlesource.com/4437 Reviewed-by: Lei Zhang Commit-Queue: Tom Sepez --- core/fxge/ge/fx_ge_linux.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'core/fxge/ge/fx_ge_linux.cpp') diff --git a/core/fxge/ge/fx_ge_linux.cpp b/core/fxge/ge/fx_ge_linux.cpp index 8d2c496c19..b216e12127 100644 --- a/core/fxge/ge/fx_ge_linux.cpp +++ b/core/fxge/ge/fx_ge_linux.cpp @@ -97,7 +97,7 @@ void* CFX_LinuxFontInfo::MapFont(int weight, for (size_t i = 0; i < kLinuxGpNameSize; i++) { auto it = m_FontList.find(g_LinuxGpFontList[index][i]); if (it != m_FontList.end()) - return it->second; + return it->second.get(); } break; } @@ -105,7 +105,7 @@ void* CFX_LinuxFontInfo::MapFont(int weight, for (size_t i = 0; i < FX_ArraySize(g_LinuxGbFontList); ++i) { auto it = m_FontList.find(g_LinuxGbFontList[i]); if (it != m_FontList.end()) - return it->second; + return it->second.get(); } break; } @@ -113,7 +113,7 @@ void* CFX_LinuxFontInfo::MapFont(int weight, for (size_t i = 0; i < FX_ArraySize(g_LinuxB5FontList); ++i) { auto it = m_FontList.find(g_LinuxB5FontList[i]); if (it != m_FontList.end()) - return it->second; + return it->second.get(); } break; } @@ -121,7 +121,7 @@ void* CFX_LinuxFontInfo::MapFont(int weight, for (size_t i = 0; i < FX_ArraySize(g_LinuxHGFontList); ++i) { auto it = m_FontList.find(g_LinuxHGFontList[i]); if (it != m_FontList.end()) - return it->second; + return it->second.get(); } break; } -- cgit v1.2.3