forked from Telodendria/Telodendria
Cross-platform code improvements.
This commit is contained in:
parent
2e1220621c
commit
e7d1c0d951
1 changed files with 4 additions and 2 deletions
|
@ -287,7 +287,7 @@ HttpServerCreate(unsigned short port, unsigned int nThreads, unsigned int maxCon
|
|||
HttpHandler * requestHandler, void *handlerArgs)
|
||||
{
|
||||
HttpServer *server;
|
||||
struct sockaddr_in sa = {0};
|
||||
struct sockaddr_in sa;
|
||||
|
||||
if (!requestHandler)
|
||||
{
|
||||
|
@ -343,6 +343,8 @@ HttpServerCreate(unsigned short port, unsigned int nThreads, unsigned int maxCon
|
|||
}
|
||||
#endif
|
||||
|
||||
memset(&sa, 0, sizeof(struct sockaddr_in));
|
||||
|
||||
sa.sin_family = AF_INET;
|
||||
sa.sin_port = htons(port);
|
||||
sa.sin_addr.s_addr = htonl(INADDR_ANY);
|
||||
|
@ -553,7 +555,7 @@ HttpServerWorkerThread(void *args)
|
|||
break;
|
||||
}
|
||||
|
||||
line[i] = tolower(line[i]);
|
||||
line[i] = tolower((unsigned char) line[i]);
|
||||
}
|
||||
|
||||
headerKey = Malloc((i + 1) * sizeof(char));
|
||||
|
|
Loading…
Reference in a new issue