2017-06-20 19:40:00 +00:00
|
|
|
#define HEADER_MAX 4096
|
|
|
|
#define FIELD_MAX 200
|
2016-09-02 07:59:02 +00:00
|
|
|
|
2017-07-11 11:52:41 +00:00
|
|
|
/* mime-types */
|
2016-09-02 07:59:02 +00:00
|
|
|
static const struct {
|
|
|
|
char *ext;
|
|
|
|
char *type;
|
|
|
|
} mimes[] = {
|
2019-01-02 16:04:23 +00:00
|
|
|
{ "xml", "application/xml; charset=utf-8" },
|
|
|
|
{ "xhtml", "application/xhtml+xml; charset=utf-8" },
|
|
|
|
{ "html", "text/html; charset=utf-8" },
|
|
|
|
{ "htm", "text/html; charset=utf-8" },
|
|
|
|
{ "css", "text/css; charset=utf-8" },
|
|
|
|
{ "txt", "text/plain; charset=utf-8" },
|
|
|
|
{ "md", "text/plain; charset=utf-8" },
|
|
|
|
{ "c", "text/plain; charset=utf-8" },
|
|
|
|
{ "h", "text/plain; charset=utf-8" },
|
2016-09-02 07:59:02 +00:00
|
|
|
{ "gz", "application/x-gtar" },
|
|
|
|
{ "tar", "application/tar" },
|
2016-09-02 09:08:54 +00:00
|
|
|
{ "pdf", "application/x-pdf" },
|
|
|
|
{ "png", "image/png" },
|
|
|
|
{ "gif", "image/gif" },
|
2017-06-27 21:15:18 +00:00
|
|
|
{ "jpeg", "image/jpg" },
|
2016-09-02 09:08:54 +00:00
|
|
|
{ "jpg", "image/jpg" },
|
|
|
|
{ "iso", "application/x-iso9660-image" },
|
|
|
|
{ "webp", "image/webp" },
|
2019-01-02 16:04:23 +00:00
|
|
|
{ "svg", "image/svg+xml; charset=utf-8" },
|
2016-09-02 09:08:54 +00:00
|
|
|
{ "flac", "audio/flac" },
|
|
|
|
{ "mp3", "audio/mpeg" },
|
2017-06-27 21:15:18 +00:00
|
|
|
{ "ogg", "audio/ogg" },
|
2016-09-02 09:08:54 +00:00
|
|
|
{ "mp4", "video/mp4" },
|
|
|
|
{ "ogv", "video/ogg" },
|
|
|
|
{ "webm", "video/webm" },
|
2016-09-02 07:59:02 +00:00
|
|
|
};
|