mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-06 05:35:47 +01:00
don't take temporary copy of MIDI sequence
fixes potential boost shared_ptr double free.
This commit is contained in:
parent
2c8babf41e
commit
f499f4cfd2
4 changed files with 11 additions and 11 deletions
|
|
@ -142,7 +142,7 @@ class AlsaMidiPort : public AlsaPort {
|
|||
DataType type () const { return DataType::MIDI; };
|
||||
|
||||
void* get_buffer (pframes_t nframes);
|
||||
const AlsaMidiBuffer const_buffer () const { return _buffer[_bufperiod]; }
|
||||
const AlsaMidiBuffer * const_buffer () const { return & _buffer[_bufperiod]; }
|
||||
|
||||
void next_period() { if (_n_periods > 1) { get_buffer(0); _bufperiod = (_bufperiod + 1) % _n_periods; } }
|
||||
void set_n_periods(int n) { if (n > 0 && n < 3) { _n_periods = n; } }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue