From 72300460c1c1fa294cc4d1f1026d203a5adf4d28 Mon Sep 17 00:00:00 2001 From: BossCode45 Date: Tue, 26 Nov 2024 15:21:56 +1300 Subject: feat: Added a program (YATmsg) to communicate with YATwm Currently just sends a hello message and nothing else, more to come later --- src/commands.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/commands.cpp') diff --git a/src/commands.cpp b/src/commands.cpp index 57cfd0b..5688da4 100644 --- a/src/commands.cpp +++ b/src/commands.cpp @@ -185,7 +185,7 @@ CommandArg* CommandsModule::getCommandArgs(vector& split, const CommandA rest += " "; } args[i-1].str = new char[rest.size()]; - strcpy(args[i-1].str, rest.c_str()); + strncpy(args[i-1].str, rest.c_str(), rest.size()); return args; } case NUM_ARR_REST: -- cgit v1.2.3