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

Unified Diff: fpdfsdk/fpdfview.cpp

Issue 2519343002: Add APIs for limited use of document tagged code. (Closed)
Patch Set: More nits Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fpdfsdk/fpdfdoc.cpp ('k') | fpdfsdk/fpdfview_c_api_test.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/fpdfview.cpp
diff --git a/fpdfsdk/fpdfview.cpp b/fpdfsdk/fpdfview.cpp
index 959bf143909b23b83876217de6b198f9ad8c12cd..3f5115afd622126efd8b6859ef2f8e42339a2ec3 100644
--- a/fpdfsdk/fpdfview.cpp
+++ b/fpdfsdk/fpdfview.cpp
@@ -1110,7 +1110,7 @@ DLLEXPORT FPDF_DEST STDCALL FPDF_GetNamedDest(FPDF_DOCUMENT document,
int len = utf16Name.GetLength();
if (!buffer) {
*buflen = len;
- } else if (*buflen >= len) {
+ } else if (len <= *buflen) {
memcpy(buffer, utf16Name.c_str(), len);
*buflen = len;
} else {
« no previous file with comments | « fpdfsdk/fpdfdoc.cpp ('k') | fpdfsdk/fpdfview_c_api_test.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698