diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2017-10-26 15:43:08 -0400 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2017-10-26 15:43:08 -0400 |
commit | 4250940ad83200e065b966d0646c75a48bb0f73d (patch) | |
tree | ae34a664f45687796d54a529ba1923bb877fa5e7 | |
parent | 997f70d9cbeb0d1a085cc7495e0a6df7721a4ab5 (diff) |
switch from std::auto_ptr<> (deprecated) to boost::scoped_ptr<>
-rw-r--r-- | libs/ardour/disk_reader.cc | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/libs/ardour/disk_reader.cc b/libs/ardour/disk_reader.cc index dd6c3ee09d..8421c04894 100644 --- a/libs/ardour/disk_reader.cc +++ b/libs/ardour/disk_reader.cc @@ -17,6 +17,8 @@ */ +#include <boost/smart_ptr/scoped_ptr.hpp> + #include "pbd/enumwriter.h" #include "pbd/memento_command.h" @@ -545,8 +547,8 @@ DiskReader::overwrite_existing_buffers () /* assume all are the same size */ samplecnt_t size = c->front()->buf->bufsize(); - std::auto_ptr<Sample> mixdown_buffer (new Sample[size]); - std::auto_ptr<float> gain_buffer (new float[size]); + boost::scoped_ptr<Sample> mixdown_buffer (new Sample[size]); + boost::scoped_ptr<float> gain_buffer (new float[size]); /* reduce size so that we can fill the buffer correctly (ringbuffers can only handle size-1, otherwise they appear to be empty) @@ -836,8 +838,8 @@ DiskReader::_do_refill_with_alloc (bool partial_fill) */ { - std::auto_ptr<Sample> mix_buf (new Sample[2*1048576]); - std::auto_ptr<float> gain_buf (new float[2*1048576]); + boost::scoped_ptr<Sample> mix_buf (new Sample[2*1048576]); + boost::scoped_ptr<float> gain_buf (new float[2*1048576]); int ret = refill_audio (mix_buf.get(), gain_buf.get(), (partial_fill ? _chunk_samples : 0)); |