summaryrefslogtreecommitdiff
path: root/src/mhd/mhd_legal.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-08-03 01:16:53 +0200
committerChristian Grothoff <christian@grothoff.org>2020-08-03 01:16:53 +0200
commitf1cc1ca2085de9b112d42f7e2c68d21e4753781b (patch)
tree5040bcdcd199660c883608d979cc52bb15d913d6 /src/mhd/mhd_legal.c
parentad27d52bdbfd0569ac9c87153c73d575beaca89e (diff)
downloadexchange-f1cc1ca2085de9b112d42f7e2c68d21e4753781b.tar.gz
exchange-f1cc1ca2085de9b112d42f7e2c68d21e4753781b.tar.bz2
exchange-f1cc1ca2085de9b112d42f7e2c68d21e4753781b.zip
expose language check logic
Diffstat (limited to 'src/mhd/mhd_legal.c')
-rw-r--r--src/mhd/mhd_legal.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/mhd/mhd_legal.c b/src/mhd/mhd_legal.c
index a6c26bbaa..7de189cce 100644
--- a/src/mhd/mhd_legal.c
+++ b/src/mhd/mhd_legal.c
@@ -165,9 +165,9 @@ xmime_matches (const char *accept_pattern,
* @return q-weight given for @a lang in @a language_pattern, 1.0 if no weights are given;
* 0 if @a lang is not in @a language_pattern
*/
-static double
-language_matches (const char *language_pattern,
- const char *lang)
+double
+TALER_MHD_language_matches (const char *language_pattern,
+ const char *lang)
{
char *p = GNUNET_strdup (language_pattern);
char *sptr;
@@ -271,10 +271,10 @@ TALER_MHD_reply_legal (struct MHD_Connection *conn,
if ( (NULL == t) ||
(! xmime_matches (mime,
t->mime_type)) ||
- (language_matches (lang,
- p->language) >
- language_matches (lang,
- t->language) ) )
+ (TALER_MHD_language_matches (lang,
+ p->language) >
+ TALER_MHD_language_matches (lang,
+ t->language) ) )
t = p;
}
}