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

Issue 1695633004: Fix the way to access marked content. (Closed)

Created:
4 years, 10 months ago by Wei Li
Modified:
4 years, 10 months ago
Reviewers:
Lei Zhang
CC:
pdfium-reviews_googlegroups.com
Base URL:
https://pdfium.googlesource.com/pdfium.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Fix the way to access marked content. When there is no dictionary for marked content, it potientially may cause crash. But it is not happening now since 1) we now check for the returned dict parameter 2) the alloc function in pdfium does zero initialization. BUG=pdfium:67 R=thestig@chromium.org Committed: https://pdfium.googlesource.com/pdfium/+/42a1bc02c0810c039afbcb62170c326f0e717320

Patch Set 1 : cleanup only #

Patch Set 2 : fix #

Total comments: 6

Patch Set 3 : address comments #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+91 lines, -61 lines) Patch
M core/include/fpdfapi/fpdf_pageobj.h View 1 2 3 chunks +4 lines, -4 lines 0 comments Download
M core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp View 1 2 4 chunks +7 lines, -9 lines 2 comments Download
M core/src/fpdfapi/fpdf_render/fpdf_render.cpp View 1 2 1 chunk +3 lines, -6 lines 0 comments Download
M core/src/fpdftext/fpdf_text_int.cpp View 1 2 42 chunks +77 lines, -42 lines 0 comments Download

Messages

Total messages: 10 (3 generated)
Wei Li
PTAL, thanks
4 years, 10 months ago (2016-02-12 23:21:10 UTC) #3
Lei Zhang
lgtm https://codereview.chromium.org/1695633004/diff/20001/core/include/fpdfapi/fpdf_pageobj.h File core/include/fpdfapi/fpdf_pageobj.h (right): https://codereview.chromium.org/1695633004/diff/20001/core/include/fpdfapi/fpdf_pageobj.h#newcode268 core/include/fpdfapi/fpdf_pageobj.h:268: typedef enum { None, PropertiesDict, DirectDict } ParamType; ...
4 years, 10 months ago (2016-02-12 23:53:27 UTC) #4
Wei Li
thanks https://codereview.chromium.org/1695633004/diff/20001/core/include/fpdfapi/fpdf_pageobj.h File core/include/fpdfapi/fpdf_pageobj.h (right): https://codereview.chromium.org/1695633004/diff/20001/core/include/fpdfapi/fpdf_pageobj.h#newcode268 core/include/fpdfapi/fpdf_pageobj.h:268: typedef enum { None, PropertiesDict, DirectDict } ParamType; ...
4 years, 10 months ago (2016-02-13 01:29:19 UTC) #5
Lei Zhang
https://codereview.chromium.org/1695633004/diff/40001/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp File core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp (right): https://codereview.chromium.org/1695633004/diff/40001/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp#newcode597 core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp:597: m_pParam = ToDictionary(src.m_pParam->Clone()); Do you still need the ToDictionary?
4 years, 10 months ago (2016-02-13 01:34:55 UTC) #6
Wei Li
https://codereview.chromium.org/1695633004/diff/40001/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp File core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp (right): https://codereview.chromium.org/1695633004/diff/40001/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp#newcode597 core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp:597: m_pParam = ToDictionary(src.m_pParam->Clone()); On 2016/02/13 01:34:55, Lei Zhang wrote: ...
4 years, 10 months ago (2016-02-13 01:41:20 UTC) #7
Lei Zhang
On 2016/02/13 01:41:20, Wei Li wrote: > https://codereview.chromium.org/1695633004/diff/40001/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp > File core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp (right): > > https://codereview.chromium.org/1695633004/diff/40001/core/src/fpdfapi/fpdf_page/fpdf_page_graph_state.cpp#newcode597 ...
4 years, 10 months ago (2016-02-13 01:43:24 UTC) #8
Wei Li
4 years, 10 months ago (2016-02-13 02:21:31 UTC) #10
Message was sent while issue was closed.
Committed patchset #3 (id:40001) manually as
42a1bc02c0810c039afbcb62170c326f0e717320 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698