mirror of
https://github.com/rwengine/openrw.git
synced 2024-11-21 18:02:43 +01:00
Fix off-by-one error putting null char into filepath
This commit is contained in:
parent
c5e6709643
commit
5f5afac574
@ -101,7 +101,7 @@ private:
|
||||
"0123456789"
|
||||
"ABCDEFGHIJKLMNOPQRSTUVWXYZ"
|
||||
"abcdefghijklmnopqrstuvwxyz";
|
||||
std::uniform_int_distribution<size_t> dist(0u, alphanum.size());
|
||||
std::uniform_int_distribution<size_t> dist(0u, alphanum.size() - 1);
|
||||
std::string res;
|
||||
res.reserve(len);
|
||||
std::generate_n(std::back_inserter(res), len, [&]() {
|
||||
|
Loading…
Reference in New Issue
Block a user