summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2018-07-02 19:23:53 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-07-02 19:23:53 +0000
commit61ff9b659a5b992e3e3ba4000f7ca5c799cc9ebf (patch)
tree327481dc21ffd9ea01676e9a174cf1a616fee5be
parent319ef06b2f695c7ebc26985d477b71fe8db93d3e (diff)
downloadpdfium-61ff9b659a5b992e3e3ba4000f7ca5c799cc9ebf.tar.xz
Comment some raw pointers that cant become UnownedPtr<>.
These appear in compile-time const data. Adding the comment makes it easier to see what work remains when using grep. Change-Id: Ibb5fe920dc9fc99dd4c866f9ddf800a58f6a67a8 Reviewed-on: https://pdfium-review.googlesource.com/36690 Reviewed-by: Lei Zhang <thestig@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
-rw-r--r--core/fpdfapi/cmaps/cmap_int.h6
-rw-r--r--core/fpdfapi/font/cpdf_cmap.cpp2
-rw-r--r--core/fpdfapi/font/cpdf_type1font.cpp4
-rw-r--r--core/fxge/cfx_fontmapper.cpp18
-rw-r--r--core/fxge/cfx_fontmgr.cpp2
-rw-r--r--xfa/fxfa/fm2js/cxfa_fmlexer.h2
6 files changed, 19 insertions, 15 deletions
diff --git a/core/fpdfapi/cmaps/cmap_int.h b/core/fpdfapi/cmaps/cmap_int.h
index 27f9617ed6..03650383cd 100644
--- a/core/fpdfapi/cmaps/cmap_int.h
+++ b/core/fpdfapi/cmaps/cmap_int.h
@@ -20,9 +20,9 @@ struct FXCMAP_DWordCIDMap {
struct FXCMAP_CMap {
enum MapType : uint8_t { Single, Range };
- const char* m_Name;
- const uint16_t* m_pWordMap;
- const FXCMAP_DWordCIDMap* m_pDWordMap;
+ const char* m_Name; // Raw, POD struct.
+ const uint16_t* m_pWordMap; // Raw, POD struct.
+ const FXCMAP_DWordCIDMap* m_pDWordMap; // Raw, POD struct.
uint16_t m_WordCount;
uint16_t m_DWordCount;
MapType m_WordMapType;
diff --git a/core/fpdfapi/font/cpdf_cmap.cpp b/core/fpdfapi/font/cpdf_cmap.cpp
index c761959d8b..f3ef829e20 100644
--- a/core/fpdfapi/font/cpdf_cmap.cpp
+++ b/core/fpdfapi/font/cpdf_cmap.cpp
@@ -23,7 +23,7 @@ struct ByteRange {
};
struct PredefinedCMap {
- const char* m_pName;
+ const char* m_pName; // Raw, POD struct.
CIDSet m_Charset;
CIDCoding m_Coding;
CPDF_CMap::CodingScheme m_CodingScheme;
diff --git a/core/fpdfapi/font/cpdf_type1font.cpp b/core/fpdfapi/font/cpdf_type1font.cpp
index 8c286edcd0..fb445832f0 100644
--- a/core/fpdfapi/font/cpdf_type1font.cpp
+++ b/core/fpdfapi/font/cpdf_type1font.cpp
@@ -20,8 +20,8 @@ namespace {
#if _FX_PLATFORM_ == _FX_PLATFORM_APPLE_
struct GlyphNameMap {
- const char* m_pStrAdobe;
- const char* m_pStrUnicode;
+ const char* m_pStrAdobe; // Raw, POD struct.
+ const char* m_pStrUnicode; // Raw, POD struct.
};
const GlyphNameMap g_GlyphNameSubsts[] = {{"ff", "uniFB00"},
diff --git a/core/fxge/cfx_fontmapper.cpp b/core/fxge/cfx_fontmapper.cpp
index e6fc984edc..c7a7015680 100644
--- a/core/fxge/cfx_fontmapper.cpp
+++ b/core/fxge/cfx_fontmapper.cpp
@@ -41,10 +41,12 @@ const char* const g_Base14FontNames[kNumStandardFonts] = {
"ZapfDingbats",
};
-const struct AltFontName {
- const char* m_pName;
+struct AltFontName {
+ const char* m_pName; // Raw, POD struct.
int m_Index;
-} g_AltFontNames[] = {
+};
+
+const AltFontName g_AltFontNames[] = {
{"Arial", 4},
{"Arial,Bold", 5},
{"Arial,BoldItalic", 6},
@@ -136,10 +138,12 @@ const struct AltFontName {
{"ZapfDingbats", 13},
};
-const struct AltFontFamily {
- const char* m_pFontName;
- const char* m_pFontFamily;
-} g_AltFontFamilies[] = {
+struct AltFontFamily {
+ const char* m_pFontName; // Raw, POD struct.
+ const char* m_pFontFamily; // Raw, POD struct.
+};
+
+const AltFontFamily g_AltFontFamilies[] = {
{"AGaramondPro", "Adobe Garamond Pro"},
{"BankGothicBT-Medium", "BankGothic Md BT"},
{"ForteMT", "Forte"},
diff --git a/core/fxge/cfx_fontmgr.cpp b/core/fxge/cfx_fontmgr.cpp
index 2ee46373d5..85999a1976 100644
--- a/core/fxge/cfx_fontmgr.cpp
+++ b/core/fxge/cfx_fontmgr.cpp
@@ -20,7 +20,7 @@
namespace {
struct BuiltinFont {
- const uint8_t* m_pFontData;
+ const uint8_t* m_pFontData; // Raw, POD struct.
uint32_t m_dwSize;
};
diff --git a/xfa/fxfa/fm2js/cxfa_fmlexer.h b/xfa/fxfa/fm2js/cxfa_fmlexer.h
index 58b193e0ec..5ce6d27bd3 100644
--- a/xfa/fxfa/fm2js/cxfa_fmlexer.h
+++ b/xfa/fxfa/fm2js/cxfa_fmlexer.h
@@ -85,7 +85,7 @@ enum XFA_FM_TOKEN {
struct XFA_FMKeyword {
XFA_FM_TOKEN m_type;
- const wchar_t* m_keyword;
+ const wchar_t* m_keyword; // Raw, POD struct.
};
class CXFA_FMToken {