mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
cecho command: don't add trailing space
Fixes centering for cechos of only punctuation.
This commit is contained in:
parent
2e748636d7
commit
e3da061192
1 changed files with 4 additions and 2 deletions
|
|
@ -777,10 +777,12 @@ static void COM_CEcho_f(void)
|
|||
size_t i;
|
||||
char cechotext[1024] = "";
|
||||
|
||||
for (i = 1; i < COM_Argc(); i++)
|
||||
strncpy(cechotext, COM_Argv(1), sizeof(cechotext)-1);
|
||||
|
||||
for (i = 2; i < COM_Argc(); i++)
|
||||
{
|
||||
strncat(cechotext, COM_Argv(i), sizeof(cechotext)-1);
|
||||
strncat(cechotext, " ", sizeof(cechotext)-1);
|
||||
strncat(cechotext, COM_Argv(i), sizeof(cechotext)-1);
|
||||
}
|
||||
|
||||
cechotext[sizeof(cechotext) - 1] = '\0';
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue