diff options
| author | Carl Hetherington <cth@carlh.net> | 2021-07-03 22:40:00 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2021-07-03 22:48:07 +0200 |
| commit | fa4da415f1788bed17eefd05ba8d49b8ad847613 (patch) | |
| tree | 3f17524f7cce451a07cb0ca64e4de996813a7932 /test | |
| parent | 2d4e8c5f69cc694625ad95dcee554499605f823b (diff) | |
Use std::vector rather than a raw array.
Diffstat (limited to 'test')
| -rw-r--r-- | test/audio_filter_test.cc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/test/audio_filter_test.cc b/test/audio_filter_test.cc index d4fc550f1..a25878637 100644 --- a/test/audio_filter_test.cc +++ b/test/audio_filter_test.cc @@ -63,9 +63,8 @@ audio_filter_impulse_test_one (AudioFilter& f, int block_size, int num_blocks) BOOST_AUTO_TEST_CASE (audio_filter_impulse_kernel_test) { AudioFilter f (0.02); - delete[] f._ir; - f._ir = new float[f._M + 1]; + f._ir.reserve(f._M + 1); f._ir[0] = 1; for (int i = 1; i <= f._M; ++i) { f._ir[i] = 0; |
