diff options
author | bungeman@google.com <bungeman@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-05-21 13:46:13 +0000 |
---|---|---|
committer | bungeman@google.com <bungeman@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-05-21 13:46:13 +0000 |
commit | e9bbee397ce96aa6642a42823feb1d7c4a8ffd8b (patch) | |
tree | fc24643afe37e880ef94c82705664b1b7fefd1f4 /src/ports | |
parent | a4d8fc24736e77fd8c588c4be63e3c15a4154860 (diff) |
Fix assignment of non-copyable.
see http://connect.microsoft.com/VisualStudio/feedback/details/552586/inherting-noncopyable-base-allows-equal-sign-initialization
git-svn-id: http://skia.googlecode.com/svn/trunk@4008 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/ports')
-rwxr-xr-x | src/ports/SkFontHost_win.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/ports/SkFontHost_win.cpp b/src/ports/SkFontHost_win.cpp index cf23e93828..2944622070 100755 --- a/src/ports/SkFontHost_win.cpp +++ b/src/ports/SkFontHost_win.cpp @@ -1432,14 +1432,13 @@ SkTypeface* SkFontHost::CreateTypefaceFromStream(SkStream* stream) { } // Change the name of the font. - SkData* rewrittenFontData = SkOTUtils::RenameFont(stream, familyName, familyNameSize-1); - if (NULL == rewrittenFontData) { + SkAutoTUnref<SkData> rewrittenFontData(SkOTUtils::RenameFont(stream, familyName, familyNameSize-1)); + if (NULL == rewrittenFontData.get()) { return NULL; } - SkAutoUnref aur = SkAutoUnref(rewrittenFontData); // Register the font with GDI. - HANDLE fontReference = activate_font(rewrittenFontData); + HANDLE fontReference = activate_font(rewrittenFontData.get()); if (NULL == fontReference) { return NULL; } |