Skip to content

Commit

Permalink
Allocate _tmp_io_bufs to the correct size.
Browse files Browse the repository at this point in the history
  • Loading branch information
brietaylor authored and essej committed Oct 11, 2021
1 parent 269af09 commit 0cf3001
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/looper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -555,6 +555,8 @@ Looper::set_buffer_size (nframes_t bufsize)
{
if (_buffersize != bufsize) {
//cerr << "setting buffer size to " << bufsize << endl;
_buffersize = bufsize;

if (_use_sync_buf == _our_syncin_buf) {
_use_sync_buf = 0;
}
Expand All @@ -577,8 +579,6 @@ Looper::set_buffer_size (nframes_t bufsize)
_tmp_io_bufs[i] = new float[_buffersize];
}

_buffersize = bufsize;

_our_syncin_buf = new float[_buffersize];
_our_syncout_buf = new float[_buffersize];
// big enough for use with resampling too
Expand Down

0 comments on commit 0cf3001

Please sign in to comment.