mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 21:32:45 +00:00
netplay_frontend.c - show_chat() - prevent warning 'format truncation' -
snprintf output between 3 and 129 bytes into a destination of size 96
This commit is contained in:
parent
cf67c102ed
commit
e0c7e78e27
@ -4857,7 +4857,7 @@ static void relay_chat(netplay_t *netplay, const char *nick, const char *msg)
|
||||
|
||||
static void show_chat(netplay_t *netplay, const char *nick, const char *msg)
|
||||
{
|
||||
char formatted_chat[NETPLAY_CHAT_MAX_SIZE];
|
||||
char formatted_chat[NETPLAY_CHAT_MAX_SIZE + 64];
|
||||
|
||||
/* Truncate the message if necessary. */
|
||||
snprintf(formatted_chat, sizeof(formatted_chat), "%s: %s", nick, msg);
|
||||
|
Loading…
x
Reference in New Issue
Block a user