Skip to content
Snippets Groups Projects
Commit d3709b89 authored by Birte Kristina Friesel's avatar Birte Kristina Friesel
Browse files

Fix bug in thumbnail generation when used with 'feh .'

It used to save the thumbnail for /path/to/./pmage.png, now it is always
/path/to/image.png
parent 25d2a1c0
No related branches found
No related tags found
No related merge requests found
git HEAD
* Fix freedesktop.org Thumbnail Managing Standard implementation:
when running feh on the current working directory, '/path/to/./image.png'
was used for thumbnail name generation. Now it is always
'/path/to/image.png'
Tue, 28 Aug 2012 11:46:19 +0200 Daniel Friesel <derf+feh@finalrewind.org>
* Release v2.6
......
......@@ -596,6 +596,9 @@ char *feh_thumbnail_get_name_uri(char *name)
/* FIXME: add support for ~, need to investigate if it's expanded
somewhere else before adding (unecessary) code */
if (name[0] != '/') {
/* work around /some/path/./image.ext */
if ((strncmp(name, "./", 2)) == 0)
name += 2;
cwd = getcwd(NULL, 0);
uri = estrjoin("/", "file:/", cwd, name, NULL);
free(cwd);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment