mirror of
https://github.com/nghttp2/nghttp2.git
synced 2025-12-08 11:08:52 +08:00
fix for segfault by reserving correct worker count
This commit is contained in:
@@ -1315,7 +1315,7 @@ int main(int argc, char **argv) {
|
|||||||
auto start = std::chrono::steady_clock::now();
|
auto start = std::chrono::steady_clock::now();
|
||||||
|
|
||||||
std::vector<std::unique_ptr<Worker>> workers;
|
std::vector<std::unique_ptr<Worker>> workers;
|
||||||
workers.reserve(config.nthreads - 1);
|
workers.reserve(config.nthreads);
|
||||||
|
|
||||||
#ifndef NOTHREADS
|
#ifndef NOTHREADS
|
||||||
std::vector<std::future<void>> futures;
|
std::vector<std::future<void>> futures;
|
||||||
|
|||||||
Reference in New Issue
Block a user