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

Issue 424883002: Don't return uninitialized memory from PDFiumEngine::Form_Response(). (Closed)

Created:
6 years, 4 months ago by Tom Sepez
Modified:
6 years, 4 months ago
Reviewers:
Lei Zhang
CC:
chromium-reviews
Project:
chromium
Visibility:
Public.

Description

Don't return uninitialized memory from PDFiumEngine::Form_Response(). If the response is too long to return in the caller-supplied buffer, truncate it to fit per the description of the app_response method in third_party/pdfium/fpdfsdk/include/fpdfformfill.h BUG=397834 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=286323

Patch Set 1 #

Patch Set 2 : Truncate. #

Patch Set 3 : API expects out-of-range return values. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+4 lines, -2 lines) Patch
M pdf/pdfium/pdfium_engine.cc View 1 2 1 chunk +4 lines, -2 lines 0 comments Download

Messages

Total messages: 13 (0 generated)
Tom Sepez
Lei, please review.
6 years, 4 months ago (2014-07-28 19:38:38 UTC) #1
Lei Zhang
In third_party/pdfium/fpdfsdk/include/fpdfformfill.h, the "Method: app_response" description says: Return Value: Number of bytes the user input ...
6 years, 4 months ago (2014-07-28 20:04:50 UTC) #2
Tom Sepez
> So maybe we do want to truncate? Yes. Serves me right for not looking ...
6 years, 4 months ago (2014-07-28 20:29:11 UTC) #3
Tom Sepez
Lei, lets try again. Thanks
6 years, 4 months ago (2014-07-28 20:39:51 UTC) #4
Lei Zhang
lgtm
6 years, 4 months ago (2014-07-28 22:21:36 UTC) #5
Tom Sepez
The CQ bit was checked by tsepez@chromium.org
6 years, 4 months ago (2014-07-29 16:02:31 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tsepez@chromium.org/424883002/20001
6 years, 4 months ago (2014-07-29 16:06:33 UTC) #7
Tom Sepez
The CQ bit was unchecked by tsepez@chromium.org
6 years, 4 months ago (2014-07-29 19:15:01 UTC) #8
Tom Sepez
Lei, per discussion with Jun, patch set #3 is actually the behaviour the API requires. ...
6 years, 4 months ago (2014-07-29 19:42:29 UTC) #9
Tom Sepez
The CQ bit was checked by tsepez@chromium.org
6 years, 4 months ago (2014-07-29 19:43:25 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tsepez@chromium.org/424883002/40001
6 years, 4 months ago (2014-07-29 19:45:03 UTC) #11
Lei Zhang
Ok, LGTM++
6 years, 4 months ago (2014-07-29 19:46:08 UTC) #12
commit-bot: I haz the power
6 years, 4 months ago (2014-07-29 22:48:22 UTC) #13
Message was sent while issue was closed.
Change committed as 286323

Powered by Google App Engine
This is Rietveld 408576698