summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2023-09-22 15:30:25 +0000
committerLaurent Bercot <ska@appnovation.com>2023-09-22 15:30:25 +0000
commit67d3d7e3fff2561a07c3c43f62db7119aac60f6b (patch)
tree2bd03a8d1e8230c65bed1b960efab2396ec94e15
parent2a8dfa840b046bc1aa6723a4fe4ee0a4551c8713 (diff)
downloadtipidee-67d3d7e3fff2561a07c3c43f62db7119aac60f6b.tar.xz
Connection: values are case-insensitive
Signed-off-by: Laurent Bercot <ska@appnovation.com>
-rw-r--r--doc/tipidee.conf.html2
-rw-r--r--src/tipideed/tipideed.c6
2 files changed, 5 insertions, 3 deletions
diff --git a/doc/tipidee.conf.html b/doc/tipidee.conf.html
index f328a62..73620bc 100644
--- a/doc/tipidee.conf.html
+++ b/doc/tipidee.conf.html
@@ -446,7 +446,7 @@ a static document under <tt>/cgi-bin</tt> or equivalent. </li>
</ul>
<div id="nph-prefix">
-<h4> nph-prefix </h4>
+<h4> <tt>nph-prefix</tt> </h4>
</div>
<p>
diff --git a/src/tipideed/tipideed.c b/src/tipideed/tipideed.c
index 46ff50a..11d67f4 100644
--- a/src/tipideed/tipideed.c
+++ b/src/tipideed/tipideed.c
@@ -1,12 +1,14 @@
/* ISC license. */
#include <skalibs/bsdsnowflake.h>
+#include <skalibs/nonposix.h>
#include <unistd.h>
#include <string.h>
#include <stdlib.h>
#include <errno.h>
+#include <skalibs/posixplz.h>
#include <skalibs/env.h>
#include <skalibs/uint16.h>
#include <skalibs/types.h>
@@ -446,8 +448,8 @@ int main (int argc, char const *const *argv, char const *const *envp)
x = tipidee_headers_search(&hdr, "Connection") ;
if (x)
{
- if (strstr(x, "close")) g.cont = 0 ;
- else if (strstr(x, "keep-alive")) g.cont = 2 ;
+ if (strcasestr(x, "close")) g.cont = 0 ;
+ else if (strcasestr(x, "keep-alive")) g.cont = 2 ;
}
}