mirror of
https://github.com/gophernicus/gophernicus.git
synced 2024-06-02 06:11:10 +00:00
Merge pull request #119 from zcrayfish/jpeg
Update menu.c: Fix JPEG detection.
This commit is contained in:
commit
4e06fd96ba
|
@ -264,7 +264,7 @@ char gopher_filetype(state *st, char *file, char magic)
|
||||||
sstrncmp(buf, "GIF87a") == MATCH) return TYPE_GIF;
|
sstrncmp(buf, "GIF87a") == MATCH) return TYPE_GIF;
|
||||||
|
|
||||||
/* JPEG images */
|
/* JPEG images */
|
||||||
if (sstrncmp(buf, "\377\330\377\340") == MATCH) return TYPE_IMAGE;
|
if (sstrncmp(buf, "\377\330\377") == MATCH) return TYPE_IMAGE;
|
||||||
|
|
||||||
/* PNG images */
|
/* PNG images */
|
||||||
if (sstrncmp(buf, "\211PNG") == MATCH) return TYPE_IMAGE;
|
if (sstrncmp(buf, "\211PNG") == MATCH) return TYPE_IMAGE;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user