array subscript is above array bounds
This commit is contained in:
parent
a79231c666
commit
108e1ad5e6
@ -372,10 +372,10 @@ string GetRandomString() {
|
||||
"ABCDEFGHIJKLMNOPQRSTUVWXYZ"
|
||||
"abcdefghijklmnopqrstuvwxyz";
|
||||
|
||||
for (int i = 0; i < 128; ++i) {
|
||||
for (int i = 0; i < 127; ++i) {
|
||||
s[i] = alphanum[rand() % (sizeof(alphanum) - 1)];
|
||||
}
|
||||
s[128] = 0;
|
||||
s[127] = 0;
|
||||
return string(s);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user