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

Unified Diff: content/common/font_config_ipc_linux.h

Issue 697383002: Fix for the font files being maped multiple times (Fontconfig). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rewritten CL to address the fact that streams can be created and passed between different threads. Created 6 years, 1 month 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 | « no previous file | content/common/font_config_ipc_linux.cc » ('j') | content/common/font_config_ipc_linux.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/font_config_ipc_linux.h
diff --git a/content/common/font_config_ipc_linux.h b/content/common/font_config_ipc_linux.h
index c5cf80f72744dac30632e84bd43563e9fa94472d..226eb6b6f720a2f2a74e67711b94e0a4c21e03ab 100644
--- a/content/common/font_config_ipc_linux.h
+++ b/content/common/font_config_ipc_linux.h
@@ -6,6 +6,8 @@
#define CONTENT_COMMON_FONT_CONFIG_IPC_LINUX_H_
#include "base/compiler_specific.h"
+#include "base/containers/hash_tables.h"
+#include "base/synchronization/lock.h"
#include "third_party/skia/include/ports/SkFontConfigInterface.h"
#include <string>
@@ -37,7 +39,15 @@ class FontConfigIPC : public SkFontConfigInterface {
};
private:
+ class MappedFontFile;
+ friend class MappedFontFile;
+
+ void RemoveMappedFontFile(MappedFontFile* mapped_font_file);
Daniel Erat 2014/11/07 15:07:36 add a comment: // Removes |mapped_font_file| fr
Krzysztof Olczyk 2015/01/14 12:42:23 Done
+
const int fd_;
+ base::Lock stream_opening_lock_;
Daniel Erat 2014/11/07 15:07:36 please add a comment documenting what this lock pr
Krzysztof Olczyk 2015/01/14 12:42:23 Done
+ // Maps font identity ID to the memory-mapped file with font data:
Daniel Erat 2014/11/07 15:07:36 s/:/./
Krzysztof Olczyk 2015/01/14 12:42:23 Done
Krzysztof Olczyk 2015/01/14 12:42:23 Done
+ base::hash_map<uint32_t, MappedFontFile*> mapped_font_files_;
};
} // namespace content
« no previous file with comments | « no previous file | content/common/font_config_ipc_linux.cc » ('j') | content/common/font_config_ipc_linux.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698