Fix typos

This commit is contained in:
Even Rouault 2020-04-28 00:49:54 +02:00
parent 8405704ebb
commit 5fb3593eba
No known key found for this signature in database
GPG Key ID: 33EBBFC47B3DD87D
9 changed files with 28 additions and 28 deletions

View File

@ -124,7 +124,7 @@ setExtraSamples(TIFF* tif, va_list ap, uint32* v)
{
TIFFWarningExt(tif->tif_clientdata,module,
"ExtraSamples tag value is changing, "
"but TransferFunction was read with a different value. Cancelling it");
"but TransferFunction was read with a different value. Canceling it");
TIFFClrFieldBit(tif,FIELD_TRANSFERFUNCTION);
_TIFFfree(td->td_transferfunction[0]);
td->td_transferfunction[0] = NULL;
@ -206,7 +206,7 @@ _TIFFVSetField(TIFF* tif, uint32 tag, va_list ap)
/*
* If the data require post-decoding processing to byte-swap
* samples, set it up here. Note that since tags are required
* to be ordered, compression code can override this behaviour
* to be ordered, compression code can override this behavior
* in the setup method if it wants to roll the post decoding
* work in with its normal work.
*/
@ -276,7 +276,7 @@ _TIFFVSetField(TIFF* tif, uint32 tag, va_list ap)
{
TIFFWarningExt(tif->tif_clientdata,module,
"SamplesPerPixel tag value is changing, "
"but SMinSampleValue tag was read with a different value. Cancelling it");
"but SMinSampleValue tag was read with a different value. Canceling it");
TIFFClrFieldBit(tif,FIELD_SMINSAMPLEVALUE);
_TIFFfree(td->td_sminsamplevalue);
td->td_sminsamplevalue = NULL;
@ -285,7 +285,7 @@ _TIFFVSetField(TIFF* tif, uint32 tag, va_list ap)
{
TIFFWarningExt(tif->tif_clientdata,module,
"SamplesPerPixel tag value is changing, "
"but SMaxSampleValue tag was read with a different value. Cancelling it");
"but SMaxSampleValue tag was read with a different value. Canceling it");
TIFFClrFieldBit(tif,FIELD_SMAXSAMPLEVALUE);
_TIFFfree(td->td_smaxsamplevalue);
td->td_smaxsamplevalue = NULL;
@ -297,7 +297,7 @@ _TIFFVSetField(TIFF* tif, uint32 tag, va_list ap)
{
TIFFWarningExt(tif->tif_clientdata,module,
"SamplesPerPixel tag value is changing, "
"but TransferFunction was read with a different value. Cancelling it");
"but TransferFunction was read with a different value. Canceling it");
TIFFClrFieldBit(tif,FIELD_TRANSFERFUNCTION);
_TIFFfree(td->td_transferfunction[0]);
td->td_transferfunction[0] = NULL;

View File

@ -55,7 +55,7 @@ static const TIFFFieldArray gpsFieldArray;
* The Rational2Double upgraded libtiff functionality allows the definition and achievement of true double-precision accuracy
* for TIFF tags of RATIONAL type and field_bit=FIELD_CUSTOM using the set_field_type = TIFF_SETGET_DOUBLE.
* Unfortunately, that changes the old implemented interface for TIFFGetField().
* In order to keep the old TIFFGetField() interface behaviour those tags have to be redefined with set_field_type = TIFF_SETGET_FLOAT!
* In order to keep the old TIFFGetField() interface behavior those tags have to be redefined with set_field_type = TIFF_SETGET_FLOAT!
*
* Rational custom arrays are already defined as _Cxx_FLOAT, thus can stay.
*

View File

@ -6439,7 +6439,7 @@ static int _TIFFFillStrilesInternal( TIFF *tif, int loadStripByteCount )
if( td->td_stripoffset_p != NULL )
return 1;
/* If tdir_count was cancelled, then we already got there, but in error */
/* If tdir_count was canceled, then we already got there, but in error */
if( td->td_stripoffset_entry.tdir_count == 0 )
return 0;

View File

@ -2700,7 +2700,7 @@ void DoubleToSrational_direct(double value, long *num, long *denom)
* (ref. e.g. https://de.wikipedia.org/wiki/Kettenbruch or https://en.wikipedia.org/wiki/Continued_fraction
* https://en.wikipedia.org/wiki/Euclidean_algorithm)
* The following functions implement the
* - ToRationalEuclideanGCD() auxiliary function which mainly implements euclidian GCD
* - ToRationalEuclideanGCD() auxiliary function which mainly implements euclidean GCD
* - DoubleToRational() conversion function for un-signed rationals
* - DoubleToSrational() conversion function for signed rationals
------------------------------------------------------------------------------------------------------------------*/
@ -2724,8 +2724,8 @@ void ToRationalEuclideanGCD(double value, int blnUseSignedRange, int blnUseSmall
unsigned long maxDenom;
/*-- nMax and fMax defines the initial accuracy of the starting fractional,
* or better, the highest used integer numbers used within the starting fractional (bigNum/bigDenom).
* There are two approaches, which can accidentially lead to different accuracies just depending on the value.
* Therefore, blnUseSmallRange steers this behaviour.
* There are two approaches, which can accidentally lead to different accuracies just depending on the value.
* Therefore, blnUseSmallRange steers this behavior.
* For long long nMax = ((9223372036854775807-1)/2); for long nMax = ((2147483647-1)/2);
*/
if (blnUseSmallRange) {
@ -2828,7 +2828,7 @@ void DoubleToRational(double value, uint32 *num, uint32 *denom)
/*-- Check for negative values. If so it is an error. */
if (value < 0) {
*num = *denom = 0;
TIFFErrorExt(0, "TIFFLib: DoubeToRational()", " Negative Value for Unsigned Rational given.");
TIFFErrorExt(0, "TIFFLib: DoubleToRational()", " Negative Value for Unsigned Rational given.");
return;
}
@ -2852,7 +2852,7 @@ void DoubleToRational(double value, uint32 *num, uint32 *denom)
}
/*-- There are two approaches using the Euclidean algorithm,
* which can accidentially lead to different accuracies just depending on the value.
* which can accidentally lead to different accuracies just depending on the value.
* Try both and define which one was better.
*/
ToRationalEuclideanGCD(value, FALSE, FALSE, &ullNum, &ullDenom);
@ -2860,9 +2860,9 @@ void DoubleToRational(double value, uint32 *num, uint32 *denom)
/*-- Double-Check, that returned values fit into ULONG :*/
if (ullNum > 0xFFFFFFFFUL || ullDenom > 0xFFFFFFFFUL || ullNum2 > 0xFFFFFFFFUL || ullDenom2 > 0xFFFFFFFFUL) {
#if defined(__WIN32__) && (defined(_MSC_VER) || defined(__MINGW32__))
TIFFErrorExt(0, "TIFFLib: DoubeToRational()", " Num or Denom exceeds ULONG: val=%14.6f, num=%I64u, denom=%I64u | num2=%I64u, denom2=%I64u", value, ullNum, ullDenom, ullNum2, ullDenom2);
TIFFErrorExt(0, "TIFFLib: DoubleToRational()", " Num or Denom exceeds ULONG: val=%14.6f, num=%I64u, denom=%I64u | num2=%I64u, denom2=%I64u", value, ullNum, ullDenom, ullNum2, ullDenom2);
#else
TIFFErrorExt(0, "TIFFLib: DoubeToRational()", " Num or Denom exceeds ULONG: val=%14.6f, num=%12llu, denom=%12llu | num2=%12llu, denom2=%12llu", value, ullNum, ullDenom, ullNum2, ullDenom2);
TIFFErrorExt(0, "TIFFLib: DoubleToRational()", " Num or Denom exceeds ULONG: val=%14.6f, num=%12llu, denom=%12llu | num2=%12llu, denom2=%12llu", value, ullNum, ullDenom, ullNum2, ullDenom2);
#endif
assert(0);
}
@ -2916,18 +2916,18 @@ void DoubleToSrational(double value, int32 *num, int32 *denom)
}
/*-- There are two approaches using the Euclidean algorithm,
* which can accidentially lead to different accuracies just depending on the value.
* which can accidentally lead to different accuracies just depending on the value.
* Try both and define which one was better.
* Furthermore, set behaviour of ToRationalEuclideanGCD() to the range of signed-long.
* Furthermore, set behavior of ToRationalEuclideanGCD() to the range of signed-long.
*/
ToRationalEuclideanGCD(value, TRUE, FALSE, &ullNum, &ullDenom);
ToRationalEuclideanGCD(value, TRUE, TRUE, &ullNum2, &ullDenom2);
/*-- Double-Check, that returned values fit into LONG :*/
if (ullNum > 0x7FFFFFFFL || ullDenom > 0x7FFFFFFFL || ullNum2 > 0x7FFFFFFFL || ullDenom2 > 0x7FFFFFFFL) {
#if defined(__WIN32__) && (defined(_MSC_VER) || defined(__MINGW32__))
TIFFErrorExt(0, "TIFFLib: DoubeToSrational()", " Num or Denom exceeds LONG: val=%14.6f, num=%I64u, denom=%I64u | num2=%I64u, denom2=%I64u", neg*value, ullNum, ullDenom, ullNum2, ullDenom2);
TIFFErrorExt(0, "TIFFLib: DoubleToSrational()", " Num or Denom exceeds LONG: val=%14.6f, num=%I64u, denom=%I64u | num2=%I64u, denom2=%I64u", neg*value, ullNum, ullDenom, ullNum2, ullDenom2);
#else
TIFFErrorExt(0, "TIFFLib: DoubeToSrational()", " Num or Denom exceeds LONG: val=%14.6f, num=%12llu, denom=%12llu | num2=%12llu, denom2=%12llu", neg*value, ullNum, ullDenom, ullNum2, ullDenom2);
TIFFErrorExt(0, "TIFFLib: DoubleToSrational()", " Num or Denom exceeds LONG: val=%14.6f, num=%12llu, denom=%12llu | num2=%12llu, denom2=%12llu", neg*value, ullNum, ullDenom, ullNum2, ullDenom2);
#endif
assert(0);
}

View File

@ -1218,7 +1218,7 @@ bad:
* from this software without specific prior written permission.
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*/
#endif /* LZW_SUPPORT */

View File

@ -74,7 +74,7 @@
or errors, up to the point where either these values are read, or it's clear they
aren't there. This means that some of the data is read twice, but we feel speed
in correcting these values is important enough to warrant this sacrifice. Although
there is currently no define or other configuration mechanism to disable this behaviour,
there is currently no define or other configuration mechanism to disable this behavior,
the actual header scanning is build to robustly respond with error report if it
should encounter an uncorrected mismatch of subsampling values. See
OJPEGReadHeaderInfoSecStreamSof.

View File

@ -165,7 +165,7 @@ TIFFClientOpen(
/*
* Process library-specific flags in the open mode string.
* The following flags may be used to control intrinsic library
* behaviour that may or may not be desirable (usually for
* behavior that may or may not be desirable (usually for
* compatibility with some application that claims to support
* TIFF but only supports some brain dead idea of what the
* vendor thinks TIFF is):
@ -206,7 +206,7 @@ TIFFClientOpen(
* not do right now.
*
* The 'M' and 'm' flags are provided because some virtual memory
* systems exhibit poor behaviour when large images are mapped.
* systems exhibit poor behavior when large images are mapped.
* These options permit clients to control the use of memory-mapped
* files on a per-file basis.
*

View File

@ -116,7 +116,7 @@ PredictorSetupDecode(TIFF* tif)
TIFFDirectory* td = &tif->tif_dir;
/* Note: when PredictorSetup() fails, the effets of setupdecode() */
/* will not be "cancelled" so setupdecode() might be robust to */
/* will not be "canceled" so setupdecode() might be robust to */
/* be called several times. */
if (!(*sp->setupdecode)(tif) || !PredictorSetup(tif))
return 0;
@ -270,8 +270,8 @@ PredictorSetupEncode(TIFF* tif)
}
/* Remarks related to C standard compliance in all below functions : */
/* - to avoid any undefined behaviour, we only operate on unsigned types */
/* since the behaviour of "overflows" is defined (wrap over) */
/* - to avoid any undefined behavior, we only operate on unsigned types */
/* since the behavior of "overflows" is defined (wrap over) */
/* - when storing into the byte stream, we explicitly mask with 0xff so */
/* as to make icc -check=conversions happy (not necessary by the standard) */

View File

@ -753,7 +753,7 @@ TIFFReadRawStrip(TIFF* tif, uint32 strip, void* buf, tmsize_t size)
}
TIFF_NOSANITIZE_UNSIGNED_INT_OVERFLOW
static uint64 NoSantizeSubUInt64(uint64 a, uint64 b)
static uint64 NoSanitizeSubUInt64(uint64 a, uint64 b)
{
return a - b;
}
@ -841,7 +841,7 @@ TIFFFillStrip(TIFF* tif, uint32 strip)
"Read error on strip %lu; "
"got %I64u bytes, expected %I64u",
(unsigned long) strip,
(unsigned __int64) NoSantizeSubUInt64(tif->tif_size, TIFFGetStrileOffset(tif, strip)),
(unsigned __int64) NoSanitizeSubUInt64(tif->tif_size, TIFFGetStrileOffset(tif, strip)),
(unsigned __int64) bytecount);
#else
TIFFErrorExt(tif->tif_clientdata, module,
@ -849,7 +849,7 @@ TIFFFillStrip(TIFF* tif, uint32 strip)
"Read error on strip %lu; "
"got %llu bytes, expected %llu",
(unsigned long) strip,
(unsigned long long) NoSantizeSubUInt64(tif->tif_size, TIFFGetStrileOffset(tif, strip)),
(unsigned long long) NoSanitizeSubUInt64(tif->tif_size, TIFFGetStrileOffset(tif, strip)),
(unsigned long long) bytecount);
#endif
tif->tif_curstrip = NOSTRIP;