From 7bda963406c4cd9d18d33c26d3de740400043985 Mon Sep 17 00:00:00 2001 From: Johannes Hofmann Date: Tue, 7 Apr 2009 16:03:06 +0200 Subject: style --- src/ImageMetaData.cxx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/ImageMetaData.cxx b/src/ImageMetaData.cxx index cda2de6..19d9e27 100644 --- a/src/ImageMetaData.cxx +++ b/src/ImageMetaData.cxx @@ -87,7 +87,7 @@ ImageMetaData::load_image_exif(char *name) { Exiv2::ExifData &exifData = image->exifData(); if (exifData.empty()) { fprintf(stderr, "%s: No Exif data found in the file", name); - return 0; + return 1; } Exiv2::ExifData::iterator pos = exifData.end(); @@ -217,7 +217,7 @@ ImageMetaData::save_image_jpgcom(char *in_img, char *out_img) { free(dirbuf); if (tmp_fd == -1) { - perror("open"); + perror("mkstemp"); return 1; } @@ -257,7 +257,6 @@ ImageMetaData::save_image_jpgcom(char *in_img, char *out_img) { _projection_type, _k0, _k1, _x0); - image->setComment(buf); try { @@ -274,7 +273,7 @@ ImageMetaData::save_image_jpgcom(char *in_img, char *out_img) { #ifdef WIN32 // Workaround as Windows does not seem to replace files on rename() struct stat stFileInfo; - if (! stat(out_img, &stFileInfo) ) + if (stat(out_img, &stFileInfo) == 0) unlink(out_img); #endif -- cgit v1.2.3