summaryrefslogtreecommitdiff
path: root/fpdfsdk/fpdf_flatten.cpp
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2018-10-02 18:01:26 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-10-02 18:01:26 +0000
commit3d3cf800a8aae4cd7ff237714e31f9a217667ad8 (patch)
tree2b982ec2f89eaf4f4d18324d7bd2126f98ea61a1 /fpdfsdk/fpdf_flatten.cpp
parente8b02fb54234ed66eeab30927b4495ecc9ca1669 (diff)
downloadpdfium-3d3cf800a8aae4cd7ff237714e31f9a217667ad8.tar.xz
Normalize widget bounding boxes when flattening.
BUG=chromium:890322 Change-Id: I11050b84cf440f8d6bb00c661360de4e389dc031 Reviewed-on: https://pdfium-review.googlesource.com/c/43290 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'fpdfsdk/fpdf_flatten.cpp')
-rw-r--r--fpdfsdk/fpdf_flatten.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/fpdfsdk/fpdf_flatten.cpp b/fpdfsdk/fpdf_flatten.cpp
index 01f3cd7e1e..a27d79f09e 100644
--- a/fpdfsdk/fpdf_flatten.cpp
+++ b/fpdfsdk/fpdf_flatten.cpp
@@ -364,6 +364,7 @@ FPDF_EXPORT int FPDF_CALLCONV FPDFPage_Flatten(FPDF_PAGE page, int nFlag) {
rcStream = pAPDic->GetRectFor("Rect");
else if (pAPDic->KeyExist("BBox"))
rcStream = pAPDic->GetRectFor("BBox");
+ rcStream.Normalize();
if (rcStream.IsEmpty())
continue;