From 8dc529bca252fea5bd2cad79036535536f31af21 Mon Sep 17 00:00:00 2001 From: Markus Uhlin Date: Sat, 16 Mar 2024 19:41:16 +0100 Subject: Replaced strcpy() with strlcpy() --- FICS/ficsmain.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'FICS') diff --git a/FICS/ficsmain.c b/FICS/ficsmain.c index bdbba7e..46cdb4d 100644 --- a/FICS/ficsmain.c +++ b/FICS/ficsmain.c @@ -44,6 +44,10 @@ #include "talkproc.h" #include "utils.h" +#if __linux__ +#include +#endif + /* Arguments */ PUBLIC int port; PUBLIC int withConsole; @@ -148,7 +152,7 @@ main(int argc, char *argv[]) } startuptime = time(NULL); - strcpy(fics_hostname, SERVER_HOSTNAME); + strlcpy(fics_hostname, SERVER_HOSTNAME, sizeof fics_hostname); game_high = 0; player_high = 0; quota_time = 60; -- cgit v1.2.3