talons

Fork of Claws Mail https://www.claws-mail
Log | Files | Refs | README | LICENSE

commit b490620975005ccfc65bd92fbe23fe8dc3a1427d
parent d33faf750fc05123e509d4cd0384159bcef610ee
Author: Paul <paul@claws-mail.org>
Date:   Sun,  8 Nov 2015 11:41:15 +0000

find correct mime type of files with no suffix, e.g. Makefile

Patch by Blatinox.

Diffstat:
MAUTHORS | 1+
Msrc/gtk/authors.h | 1+
Msrc/procmime.c | 2++
3 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/AUTHORS b/AUTHORS @@ -306,3 +306,4 @@ contributors (in addition to the above; based on Changelog) Daniel Jakots Mikhail Kurinnoi Arthur Huillet + Blatinox diff --git a/src/gtk/authors.h b/src/gtk/authors.h @@ -94,6 +94,7 @@ static char *CONTRIBS_LIST[] = { "Sébastien Bigaret", "Laurent Bigonville", "Jean-Luc Biord", +"Blatinox", "Pavlo Bohmat", "H. Merijn Brand", "Eugene Brevdo", diff --git a/src/procmime.c b/src/procmime.c @@ -1104,6 +1104,8 @@ gchar *procmime_get_mime_type(const gchar *filename) base = g_path_get_basename(filename); if ((p = strrchr(base, '.')) != NULL) ext = g_utf8_strdown(p + 1, -1); + else + ext = g_utf8_strdown(base, -1); g_free(base); #ifndef G_OS_WIN32