Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(500)

Unified Diff: skia/ext/SkFontHost_fontconfig_direct.cpp

Issue 507037: Returns an error immediately without sending IPC message when a font family n... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/renderer_host/render_sandbox_host_linux.cc ('k') | skia/ext/SkFontHost_fontconfig_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: skia/ext/SkFontHost_fontconfig_direct.cpp
===================================================================
--- skia/ext/SkFontHost_fontconfig_direct.cpp (revision 34817)
+++ skia/ext/SkFontHost_fontconfig_direct.cpp (working copy)
@@ -46,6 +46,9 @@
bool fileid_valid, unsigned fileid,
const std::string& family, bool* is_bold,
bool* is_italic) {
+ if (family.length() > kMaxFontFamilyLength)
+ return false;
+
SkAutoMutexAcquire ac(mutex_);
FcPattern* pattern = FcPatternCreate();
« no previous file with comments | « chrome/browser/renderer_host/render_sandbox_host_linux.cc ('k') | skia/ext/SkFontHost_fontconfig_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698