diff options
author | 2014-06-05 20:36:12 +0000 | |
---|---|---|
committer | 2014-06-05 20:36:12 +0000 | |
commit | b19a5ff5ec18c7b9c562161274c86dd6b5737e5c (patch) | |
tree | 0b350117cccea0811b4ef09cd1d0e26566874eee | |
parent | be59130c0b458aaa12bb8cceec227e1f96810caa (diff) |
Allow '+' char in blessMime
See this one [1] for an example
[1] - http://www.w3.org/TR/SVGTiny12/mimereg.html
-rw-r--r-- | src/c/urweb.c | 2 | ||||
-rw-r--r-- | src/settings.sml | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/c/urweb.c b/src/c/urweb.c index e337424a..020e69d4 100644 --- a/src/c/urweb.c +++ b/src/c/urweb.c @@ -3604,7 +3604,7 @@ uw_Basis_string uw_Basis_checkUrl(uw_context ctx, uw_Basis_string s) { static int mime_format(const char *s) { for (; *s; ++s) - if (!isalnum((int)*s) && *s != '/' && *s != '-' && *s != '.') + if (!isalnum((int)*s) && *s != '/' && *s != '-' && *s != '.' && *s != '+') return 0; return 1; diff --git a/src/settings.sml b/src/settings.sml index f00a4853..ec05d84d 100644 --- a/src/settings.sml +++ b/src/settings.sml @@ -465,7 +465,7 @@ fun check f rules s = val checkUrl = check (fn _ => true) url -val validMime = CharVector.all (fn ch => Char.isAlphaNum ch orelse ch = #"/" orelse ch = #"-" orelse ch = #".") +val validMime = CharVector.all (fn ch => Char.isAlphaNum ch orelse ch = #"/" orelse ch = #"-" orelse ch = #"." orelse ch = #"+") val validEnv = CharVector.all (fn ch => Char.isAlphaNum ch orelse ch = #"_" orelse ch = #".") val checkMime = check validMime mime |