summaryrefslogtreecommitdiff
path: root/frontends/monkey/filetype.c
diff options
context:
space:
mode:
Diffstat (limited to 'frontends/monkey/filetype.c')
-rw-r--r--frontends/monkey/filetype.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/frontends/monkey/filetype.c b/frontends/monkey/filetype.c
index 65c84f9bd..37853a63d 100644
--- a/frontends/monkey/filetype.c
+++ b/frontends/monkey/filetype.c
@@ -69,8 +69,10 @@ void monkey_fetch_filetype_init(const char *mimefile)
hash_add(mime_hash, "html", "text/html");
hash_add(mime_hash, "jpg", "image/jpeg");
hash_add(mime_hash, "jpeg", "image/jpeg");
+ hash_add(mime_hash, "bmp", "image/bmp");
hash_add(mime_hash, "gif", "image/gif");
hash_add(mime_hash, "png", "image/png");
+ hash_add(mime_hash, "ico", "image/ico");
hash_add(mime_hash, "jng", "image/jng");
hash_add(mime_hash, "mng", "image/mng");
hash_add(mime_hash, "webp", "image/webp");
@@ -108,9 +110,9 @@ void monkey_fetch_filetype_init(const char *mimefile)
type = ptr;
- /* search for the first non-whitespace char or NUL or
+ /* search for the first whitespace char or NUL or
* NL */
- while (*ptr && (!ascii_is_space(*ptr)) && *ptr != '\n')
+ while (*ptr && (!ascii_is_space(*ptr)))
ptr++;
if (*ptr == '\0' || *ptr == '\n') {
@@ -133,8 +135,7 @@ void monkey_fetch_filetype_init(const char *mimefile)
/* search for the first whitespace char or
* NUL or NL which is the end of the ext.
*/
- while (*ptr && (!ascii_is_space(*ptr)) &&
- *ptr != '\n')
+ while (*ptr && (!ascii_is_space(*ptr)))
ptr++;
if (*ptr == '\0' || *ptr == '\n') {