[SCM] exiv2 packaging branch, master, updated. debian/0.25-3.1-3734-gdcbc29a
Maximiliano Curia
maxy at moszumanska.debian.org
Thu Jul 13 17:46:15 UTC 2017
Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-extras/exiv2.git;a=commitdiff;h=a769e1a
The following commit has been merged in the master branch:
commit a769e1a0fc67430cabe9092051e72266b5a5d84c
Author: Robin Mills <robin at clanmills.com>
Date: Sun Jan 31 23:39:04 2016 +0000
#1159. Fixing MSVC build-breaker in r4197 and r4179.
Two different issues:
r4197 include <windef.h> does not compile with MSVC 2005 and changed to <windows.h>
r4179 has a short/long compare mismatch
MSVC is a severe build environment and treats warnings as errors. MSVC is not fragile, it's robust.
---
src/jpgimage.cpp | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/src/jpgimage.cpp b/src/jpgimage.cpp
index 50fbea6..493ecd6 100644
--- a/src/jpgimage.cpp
+++ b/src/jpgimage.cpp
@@ -41,7 +41,7 @@ EXIV2_RCSID("@(#) $Id$")
#include "futils.hpp"
#ifdef WIN32
-#include <windef.h>
+#include <windows.h>
#else
#define BYTE char
#define USHORT uint16_t
@@ -671,12 +671,13 @@ namespace Exiv2 {
io_->seek(-bufRead , BasicIo::cur);
io_->read(exif,size);
uint32_t start = std::strcmp(http,"Exif")==0 ? 8 : 6;
+ uint32_t max = (uint32_t) size -1;
// is this an fff block?
if ( bFlir ) {
start = 0 ;
bFlir = false;
- while ( start < size-1 ) {
+ while ( start < max ) {
if ( std::strcmp((const char*)(exif+start),"FFF")==0 ) {
bFlir = true ;
break;
@@ -689,18 +690,18 @@ namespace Exiv2 {
// Hunt down the tiff using brute force
if ( bFlir ) {
// FLIRFILEHEAD* pFFF = (FLIRFILEHEAD*) (exif+start) ;
- while ( start < size-1 ) {
+ while ( start < max ) {
if ( exif[start] == 'I' && exif[start+1] == 'I' ) break;
if ( exif[start] == 'M' && exif[start+1] == 'M' ) break;
start++;
}
- if ( start < (size-10) ) std::cout << " FFF start = " << start << std::endl ;
+ if ( start < max ) std::cout << " FFF start = " << start << std::endl ;
// << " index = " << pFFF->dwIndexOff << std::endl;
}
// create a copy on write memio object with the data, then print the structure
BasicIo::AutoPtr p = BasicIo::AutoPtr(new MemIo(exif+start,size-start));
- if ( start < (size-10) ) TiffImage::printTiffStructure(*p,out,option,depth);
+ if ( start < max ) TiffImage::printTiffStructure(*p,out,option,depth);
// restore and clean up
io_->seek(restore,Exiv2::BasicIo::beg);
--
exiv2 packaging
More information about the pkg-kde-commits
mailing list