1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-12-26 01:50:36 +00:00

rogueviz:: dhrg:: fixed VLA

This commit is contained in:
Zeno Rogue 2024-04-28 02:09:19 +02:00
parent de20daf708
commit 329ad76c3c

View File

@ -337,8 +337,7 @@ void build_disttable_approx() {
for(int k=0; k<threads; k++) for(int k=0; k<threads; k++)
v.emplace_back([&,k] () { v.emplace_back([&,k] () {
auto& dt = results[k]; auto& dt = results[k];
int tab[N]; vector<int> tab(N, N);
for(int i=0; i<N; i++) tab[i] = N;
auto p = k ? nullptr : new progressbar(N/threads, "build_disttable_approx"); auto p = k ? nullptr : new progressbar(N/threads, "build_disttable_approx");
for(int i=k; i<N; i+=threads) { for(int i=k; i<N; i+=threads) {
if(p) (*p)++; if(p) (*p)++;