Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

fix: some exif related problems resolved #80

Closed
wants to merge 3 commits into from

2 participants

@reald
  • fixed uninitialized pointer, crash in thumbnail mode (filelist.c)
  • improved handling of images which have exif tags but not ours (exif.c, imlib.c)
  • added nikon lens info if available (exif.c)
reald added some commits
@reald reald - improved handling of images which have exif tags but not ours
- fixed uninitialzed pointer in thumbnail mode
- added nikon lens info if available
132ecc0
@reald reald - improved handling of images which have exif tags but not ours
- fixed uninitialized pointer in thumbnail mode
- added nikon lens info if available
e4483e5
@reald reald Merge branch 'master' of ssh://github.com/reald/feh 9c8226a
@derf
Owner

Merged, thanks!

@derf derf closed this pull request from a commit
@derf EXIF fixes by reald (closes #80)
commit 9c8226a
Merge: e4483e5 132ecc0
Author: Dennis Real <github@tildepipe.org>
Date:   Sun Feb 5 17:24:17 2012 +0100

    Merge branch 'master' of ssh://github.com/reald/feh

commit e4483e5
Author: Dennis Real <github@tildepipe.org>
Date:   Sun Feb 5 16:56:29 2012 +0100

    - improved handling of images which have exif tags but not ours
    - fixed uninitialized pointer in thumbnail mode
    - added nikon lens info if available

commit 132ecc0
Author: Dennis Real <github@tildepipe.org>
Date:   Sun Feb 5 16:56:29 2012 +0100

    - improved handling of images which have exif tags but not ours
    - fixed uninitialzed pointer in thumbnail mode
    - added nikon lens info if available
b1e497e
@derf derf closed this in b1e497e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Feb 5, 2012
  1. @reald

    - improved handling of images which have exif tags but not ours

    reald authored
    - fixed uninitialzed pointer in thumbnail mode
    - added nikon lens info if available
  2. @reald

    - improved handling of images which have exif tags but not ours

    reald authored
    - fixed uninitialized pointer in thumbnail mode
    - added nikon lens info if available
  3. @reald
This page is out of date. Refresh to see the latest.
View
1  .gitignore
@@ -3,3 +3,4 @@
/src/*.inc
/src/feh
/man/*.1
+*~
View
2  config.mk
@@ -21,7 +21,7 @@ curl ?= 1
debug ?= 0
help ?= 0
xinerama ?= 1
-exif ?= 0
+exif ?= 1
ifeq (${curl},1)
CFLAGS += -DHAVE_LIBCURL
View
8 src/exif.c
@@ -45,10 +45,10 @@ static void exif_trim_spaces(char *str)
{
if (*str != ' ')
{
- end = str;
+ end = str+1;
}
}
- *++end = '\0';
+ *end = '\0';
}
@@ -146,7 +146,7 @@ void exif_get_info(ExifData * ed, char *buffer, unsigned int maxsize)
{
return;
}
- else if (ed == NULL )
+ else if (ed == NULL)
{
snprintf(buffer, (size_t)maxsize, "%s\n", "No Exif data in file.");
return;
@@ -187,6 +187,8 @@ void exif_get_info(ExifData * ed, char *buffer, unsigned int maxsize)
{
/* Digital Vari-Program */
exif_get_mnote_tag(ed, 171, buffer + strlen(buffer), maxsize - strlen(buffer));
+ /* Lens */
+ exif_get_mnote_tag(ed, 132, buffer + strlen(buffer), maxsize - strlen(buffer));
}
}
View
5 src/filelist.c
@@ -54,6 +54,9 @@ feh_file *feh_file_new(char *filename)
else
newfile->name = estrdup(filename);
newfile->info = NULL;
+#ifdef HAVE_LIBEXIF
+ newfile->ed = NULL;
+#endif
return(newfile);
}
@@ -70,7 +73,7 @@ void feh_file_free(feh_file * file)
if (file->info)
feh_file_info_free(file->info);
#ifdef HAVE_LIBEXIF
- if (file->info)
+ if (file->ed)
exif_data_unref(file->ed);
#endif
free(file);
View
2  src/imlib.c
@@ -522,6 +522,8 @@ void feh_draw_exif(winwidget w)
return;
}
+
+ buffer[0] = '\0';
exif_get_info(FEH_FILE(w->file->data)->ed, buffer, MAX_EXIF_DATA);
fn = feh_load_font(w);
Something went wrong with that request. Please try again.