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

Unified Diff: third_party/libtiff/tif_print.c

Issue 1563103002: XFA: Upgrade to libtiff 4.0.6. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: rename to libtiff Created 4 years, 11 months 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 | « third_party/libtiff/tif_predict.c ('k') | third_party/libtiff/tif_read.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/libtiff/tif_print.c
diff --git a/third_party/tiff_v403/tif_print.c b/third_party/libtiff/tif_print.c
similarity index 97%
rename from third_party/tiff_v403/tif_print.c
rename to third_party/libtiff/tif_print.c
index f93e557f5cec411700bf59ba89927009b11eac2e..7b1a4222a3bcb3252e3c79d67bf1820e921473b6 100644
--- a/third_party/tiff_v403/tif_print.c
+++ b/third_party/libtiff/tif_print.c
@@ -1,4 +1,4 @@
-/* $Id: tif_print.c,v 1.60 2012-08-19 16:56:35 bfriesen Exp $ */
+/* $Id: tif_print.c,v 1.62 2015-08-19 02:31:04 bfriesen Exp $ */
/*
* Copyright (c) 1988-1997 Sam Leffler
@@ -35,7 +35,7 @@
#include <ctype.h>
static void
-_TIFFprintAsciiBounded(FILE* fd, const char* cp, int max_chars);
+_TIFFprintAsciiBounded(FILE* fd, const char* cp, size_t max_chars);
static const char *photoNames[] = {
"min-is-white", /* PHOTOMETRIC_MINISWHITE */
@@ -395,8 +395,8 @@ TIFFPrintDirectory(TIFF* tif, FILE* fd, long flags)
for (cp = td->td_inknames;
i > 0 && cp < td->td_inknames + td->td_inknameslen;
cp = strchr(cp,'\0')+1, i--) {
- int max_chars =
- (int)(td->td_inknameslen - (cp - td->td_inknames));
+ size_t max_chars =
+ td->td_inknameslen - (cp - td->td_inknames);
fputs(sep, fd);
_TIFFprintAsciiBounded(fd, cp, max_chars);
sep = ", ";
@@ -582,10 +582,10 @@ TIFFPrintDirectory(TIFF* tif, FILE* fd, long flags)
continue;
if(fip->field_passcount) {
- if (fip->field_readcount == TIFF_VARIABLE ) {
+ if (fip->field_readcount == TIFF_VARIABLE2 ) {
if(TIFFGetField(tif, tag, &value_count, &raw_data) != 1)
continue;
- } else if (fip->field_readcount == TIFF_VARIABLE2 ) {
+ } else if (fip->field_readcount == TIFF_VARIABLE ) {
uint16 small_value_count;
if(TIFFGetField(tif, tag, &small_value_count, &raw_data) != 1)
continue;
@@ -675,11 +675,11 @@ TIFFPrintDirectory(TIFF* tif, FILE* fd, long flags)
void
_TIFFprintAscii(FILE* fd, const char* cp)
{
- _TIFFprintAsciiBounded( fd, cp, (int)strlen(cp));
+ _TIFFprintAsciiBounded( fd, cp, strlen(cp));
}
static void
-_TIFFprintAsciiBounded(FILE* fd, const char* cp, int max_chars)
+_TIFFprintAsciiBounded(FILE* fd, const char* cp, size_t max_chars)
{
for (; max_chars > 0 && *cp != '\0'; cp++, max_chars--) {
const char* tp;
@@ -714,4 +714,3 @@ _TIFFprintAsciiTag(FILE* fd, const char* name, const char* value)
* fill-column: 78
* End:
*/
-
« no previous file with comments | « third_party/libtiff/tif_predict.c ('k') | third_party/libtiff/tif_read.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698