From: nishi Date: Tue, 30 Jan 2024 15:44:21 +0000 (+0000) Subject: fixing w3b X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=eef9002553aecb2eb27514a644689e0fc7e790fc;p=libw3.git fixing w3b git-svn-id: file:///raid/svn-main/nishi-libw3/trunk@142 d27a3e52-49c5-7645-884c-6793ebffc270 --- diff --git a/Example/w3b/w3b.c b/Example/w3b/w3b.c index 2348094..31535b6 100644 --- a/Example/w3b/w3b.c +++ b/Example/w3b/w3b.c @@ -65,6 +65,13 @@ void header_handler(struct W3* w3, char* key, char* value) { if(strcasecmp(key, "content-type") == 0) { if(ctype != NULL) free(ctype); ctype = __W3_Strdup(value); + int i; + for(i = 0; ctype[i] != 0; i++) { + if(ctype[i] == ';') { + ctype[i] = 0; + break; + } + } } }