1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

test-cmp: fix initialisation order

This commit is contained in:
Steffen Vogel 2019-06-20 09:50:14 +02:00
parent f2776109c5
commit 2a7d876f7c

View file

@ -218,15 +218,15 @@ check: if (optarg == endptr)
if (!fmt)
throw RuntimeError("Invalid IO format: {}", format);
ret = pool_init(&pool, filenames.size(), SAMPLE_LENGTH(DEFAULT_SAMPLE_LENGTH), &memory_heap);
if (ret)
throw RuntimeError("Failed to initialize pool");
/* Open files */
std::vector<TestCmpSide *> sides;
for (auto filename : filenames)
sides.push_back(new TestCmpSide(filename, fmt, dtypes, &pool));
ret = pool_init(&pool, sides.size(), SAMPLE_LENGTH(DEFAULT_SAMPLE_LENGTH), &memory_heap);
if (ret)
throw RuntimeError("Failed to initialize pool");
line = 0;
for (;;) {
/* Read next sample from all files */