Remove libbsd and strlcpy

This commit is contained in:
Tobias Reisinger 2020-11-19 23:36:02 +01:00
parent 3f11431df6
commit 1f315d2b92
15 changed files with 53 additions and 50 deletions
src/handlers

View file

@ -1,4 +1,3 @@
#include <bsd/string.h>
#include <string.h>
#include <status.h>
@ -22,7 +21,8 @@ add_extra_headers(char *extra_headers)
if(extra_headers == NULL)
{
result = malloc(sizeof(char) * (std_headers_len + 1));
strlcpy(result, global_config->http_server_opts.extra_headers, std_headers_len + 1);
strcpy(result, global_config->http_server_opts.extra_headers);
result[std_headers_len] = '\0';
return result;
}