X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=libcitadel%2Flib%2Fmime_parser.c;fp=libcitadel%2Flib%2Fmime_parser.c;h=2e81fe8b07bcca291cd2ed736d41d7d0fb93b8e8;hb=e3f6ab99716cc32ae913a92b5ed4b351eff65a41;hp=1fc037d43ffd77462434eb93f645001f4dbb251a;hpb=7b3fab89fd3bf8487596ec6d3ca2194ceb0fed28;p=citadel.git diff --git a/libcitadel/lib/mime_parser.c b/libcitadel/lib/mime_parser.c index 1fc037d43..2e81fe8b0 100644 --- a/libcitadel/lib/mime_parser.c +++ b/libcitadel/lib/mime_parser.c @@ -982,6 +982,8 @@ const char* GuessMimeByFilename(const char *what, size_t len) return "text/x-component"; else if ((len > 3) && !strncasecmp(&what[len - 4], ".jpg", 4)) return "image/jpeg"; + else if ((len > 4) && !strncasecmp(&what[len - 5], ".jpeg", 5)) + return "image/jpeg"; else if ((len > 3) && !strncasecmp(&what[len - 4], ".png", 4)) return "image/png"; else if ((len > 3) && !strncasecmp(&what[len - 4], ".ico", 4))