diff options
author | Omar Polo <op@omarpolo.com> | 2023-06-09 17:18:04 +0000 |
---|---|---|
committer | Omar Polo <op@omarpolo.com> | 2023-06-09 17:18:04 +0000 |
commit | af1dab18702cf135aa80bf15065f73050c915347 (patch) | |
tree | 0313c88a607ca1079a63a5c6d86df04cc606d649 /mime.c | |
parent | e45334e6ae0b658a2d3d4f47bc3e9ddfdb83a44f (diff) |
don't have the config being a global
Diffstat (limited to 'mime.c')
-rw-r--r-- | mime.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -136,7 +136,7 @@ mime_find(const void *a, const void *b) } const char * -mime(struct vhost *host, const char *path) +mime(struct conf *conf, struct vhost *host, const char *path) { const char *def, *ext; struct etm *t; @@ -146,7 +146,7 @@ mime(struct vhost *host, const char *path) if ((ext = path_ext(path)) == NULL) return def; - t = bsearch(ext, conf.mime.t, conf.mime.len, sizeof(*conf.mime.t), + t = bsearch(ext, conf->mime.t, conf->mime.len, sizeof(*conf->mime.t), mime_find); if (t != NULL) return t->mime; |