summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohannes Hofmann <Johannes.Hofmann@gmx.de>2009-04-07 16:03:06 +0200
committerJohannes Hofmann <Johannes.Hofmann@gmx.de>2009-04-07 16:03:06 +0200
commit7bda963406c4cd9d18d33c26d3de740400043985 (patch)
tree2d6ad92503089657d5c1d1138e47b842da7c2704 /src
parente81e5f4db0d3757ce311d1b81a7b0c6afc9162c9 (diff)
style
Diffstat (limited to 'src')
-rw-r--r--src/ImageMetaData.cxx7
1 files changed, 3 insertions, 4 deletions
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