diff options
author | Patric Stout <truebrain@openttd.org> | 2021-05-29 11:21:38 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-29 11:21:38 +0200 |
commit | ca9a7df7522a614b839a83e1ba9b6a7b08642b8a (patch) | |
tree | 172dedad1d930ef7699838272e779c9d7218319b /src/network | |
parent | 4d74e519074bec9a07c2997715ab635ac0e8f084 (diff) | |
download | openttd-ca9a7df7522a614b839a83e1ba9b6a7b08642b8a.tar.xz |
Codechange: rename str_validate to StrMakeValid(InPlace) (#9304)
This to be more explicit the function changes the value, and not
returns yes/no.
Diffstat (limited to 'src/network')
-rw-r--r-- | src/network/core/packet.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/network/core/packet.cpp b/src/network/core/packet.cpp index 738afec4e..c27a37d46 100644 --- a/src/network/core/packet.cpp +++ b/src/network/core/packet.cpp @@ -394,7 +394,7 @@ void Packet::Recv_string(char *buffer, size_t size, StringValidationSettings set assert(pos <= std::numeric_limits<PacketSize>::max()); this->pos = static_cast<PacketSize>(pos); - str_validate(bufp, last, settings); + StrMakeValidInPlace(bufp, last, settings); } /** @@ -423,7 +423,7 @@ std::string Packet::Recv_string(size_t length, StringValidationSettings settings while (this->Recv_uint8() != '\0') {} } - return str_validate(str, settings); + return StrMakeValid(str, settings); } /** |