1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-20 04:59:11 +00:00

Codechange: Replaced SmallVector::Get(n) non-const with std::vector::data() + n

This commit is contained in:
Henry Wilson
2018-09-25 21:01:56 +01:00
committed by PeterN
parent bc7dcaffca
commit aa7ca7fe64
9 changed files with 10 additions and 23 deletions

View File

@@ -566,7 +566,7 @@ DEF_CONSOLE_CMD(ConUnBan)
seprintf(msg, lastof(msg), "Unbanned %s", _network_ban_list[index]);
IConsolePrint(CC_DEFAULT, msg);
free(_network_ban_list[index]);
_network_ban_list.Erase(_network_ban_list.Get(index));
_network_ban_list.erase(_network_ban_list.begin() + index);
} else {
IConsolePrint(CC_DEFAULT, "Invalid list index or IP not in ban-list.");
IConsolePrint(CC_DEFAULT, "For a list of banned IP's, see the command 'banlist'");