Commit MetaInfo

Revision2349f2b3afeb956ea1c145e001d1064dfc571205 (tree)
Time2021-05-01 22:11:20
AuthorAdam Kaminski <kaminskiadam9@gmai...>
CommiterAdam Kaminski

Log Message

Fixed a crash if the server tries sending a private message to a player.

Change Summary

Incremental Difference

diff -r e0396026bee9 -r 2349f2b3afeb src/sv_commands.cpp
--- a/src/sv_commands.cpp Sat May 01 08:56:12 2021 -0400
+++ b/src/sv_commands.cpp Sat May 01 09:11:20 2021 -0400
@@ -1092,7 +1092,7 @@
10921092 }
10931093
10941094 // [AK] Don't send the command if the sender is supposed to be ignoring the player who receives the message.
1095- if ( SERVER_GetPlayerIgnoreTic( ulSender, SERVER_GetClient( ulReceiver )->Address ) != 0 )
1095+ if (( ulSender != MAXPLAYERS ) && ( SERVER_GetPlayerIgnoreTic( ulSender, SERVER_GetClient( ulReceiver )->Address ) != 0 ))
10961096 {
10971097 SERVER_PrintfPlayer( ulSender, "You have ignored %s on your end, so you can't send any private messages to them.\n",
10981098 players[ulReceiver].userinfo.GetName() );
Show on old repository browser