From cf76d9e12195727d1832a13caf1135a7873d557f Mon Sep 17 00:00:00 2001 From: twinaphex Date: Sat, 26 Nov 2016 17:13:14 +0100 Subject: [PATCH] (civetweb) Use strlcpy/strlcat --- deps/civetweb/civetweb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/deps/civetweb/civetweb.c b/deps/civetweb/civetweb.c index b4653e78d3..448946269a 100644 --- a/deps/civetweb/civetweb.c +++ b/deps/civetweb/civetweb.c @@ -5654,8 +5654,8 @@ mg_modify_passwords_file(const char *fname, } /* Create a temporary file name. Length has been checked before. */ - strcpy(tmp, fname); - strcat(tmp, ".tmp"); + strlcpy(tmp, fname, sizeof(tmp)); + strlcat(tmp, ".tmp", sizeof(tmp)); /* Create the file if does not exist */ /* Use of fopen here is OK, since fname is only ASCII */