diff options
author | Lei Zhang <thestig@chromium.org> | 2018-01-10 17:33:06 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-01-10 17:33:06 +0000 |
commit | 50bd8fa8a9505487c1109e2645ef785ad73b1cbc (patch) | |
tree | 09853cec7a8cbc32e3f5f5222db654f31907b097 /fpdfsdk/fpdftext_embeddertest.cpp | |
parent | 54f86140d436ce2f457dc588f5b2c183d4e94452 (diff) | |
download | pdfium-50bd8fa8a9505487c1109e2645ef785ad73b1cbc.tar.xz |
Change FPDFLink_GetRect() to return a boolean.
BUG=pdfium:858
Change-Id: Ib8effb64a1622feb2837f536b36b9e46847a2210
Reviewed-on: https://pdfium-review.googlesource.com/22631
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'fpdfsdk/fpdftext_embeddertest.cpp')
-rw-r--r-- | fpdfsdk/fpdftext_embeddertest.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fpdfsdk/fpdftext_embeddertest.cpp b/fpdfsdk/fpdftext_embeddertest.cpp index 60654057b9..6885eb0f75 100644 --- a/fpdfsdk/fpdftext_embeddertest.cpp +++ b/fpdfsdk/fpdftext_embeddertest.cpp @@ -365,7 +365,7 @@ TEST_F(FPDFTextEmbeddertest, WebLinks) { double right = 0.0; double top = 0.0; double bottom = 0.0; - FPDFLink_GetRect(pagelink, 0, 0, &left, &top, &right, &bottom); + EXPECT_TRUE(FPDFLink_GetRect(pagelink, 0, 0, &left, &top, &right, &bottom)); EXPECT_NEAR(50.791, left, 0.001); EXPECT_NEAR(187.963, right, 0.001); EXPECT_NEAR(97.624, bottom, 0.001); @@ -376,7 +376,7 @@ TEST_F(FPDFTextEmbeddertest, WebLinks) { right = -1.0; top = -1.0; bottom = -1.0; - FPDFLink_GetRect(pagelink, 0, 1, &left, &top, &right, &bottom); + EXPECT_FALSE(FPDFLink_GetRect(pagelink, 0, 1, &left, &top, &right, &bottom)); EXPECT_EQ(-1.0, left); EXPECT_EQ(-1.0, right); EXPECT_EQ(-1.0, bottom); @@ -387,7 +387,7 @@ TEST_F(FPDFTextEmbeddertest, WebLinks) { right = -2.0; top = -2.0; bottom = -2.0; - FPDFLink_GetRect(pagelink, -1, 0, &left, &top, &right, &bottom); + EXPECT_FALSE(FPDFLink_GetRect(pagelink, -1, 0, &left, &top, &right, &bottom)); EXPECT_EQ(-2.0, left); EXPECT_EQ(-2.0, right); EXPECT_EQ(-2.0, bottom); |