diff options
author | Martin Braun <martin.braun@ettus.com> | 2021-01-08 09:33:36 +0100 |
---|---|---|
committer | Aaron Rossetto <aaron.rossetto@ni.com> | 2021-03-04 08:07:26 -0600 |
commit | 107a49c0c236940da7d3bd0f57da4bc1e2a34cb4 (patch) | |
tree | fdeaad56030a02948377c45838dab97beb7a5c84 /host/lib/transport/muxed_zero_copy_if.cpp | |
parent | 7d5e48032baa62cbe7467833b9e057900602f4b9 (diff) | |
download | uhd-107a49c0c236940da7d3bd0f57da4bc1e2a34cb4.tar.gz uhd-107a49c0c236940da7d3bd0f57da4bc1e2a34cb4.tar.bz2 uhd-107a49c0c236940da7d3bd0f57da4bc1e2a34cb4.zip |
host: Update code base using clang-tidy
The checks from the new clang-tidy file are applied to the source tree
using:
$ find . -name "*.cpp" | sort -u | xargs \
--max-procs 8 --max-args 1 clang-tidy --format-style=file \
--fix -p /path/to/compile_commands.json
Diffstat (limited to 'host/lib/transport/muxed_zero_copy_if.cpp')
-rw-r--r-- | host/lib/transport/muxed_zero_copy_if.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/host/lib/transport/muxed_zero_copy_if.cpp b/host/lib/transport/muxed_zero_copy_if.cpp index 2602d8596..f7cc88c9c 100644 --- a/host/lib/transport/muxed_zero_copy_if.cpp +++ b/host/lib/transport/muxed_zero_copy_if.cpp @@ -39,7 +39,7 @@ public: boost::thread(std::bind(&muxed_zero_copy_if_impl::_update_queues, this)); } - virtual ~muxed_zero_copy_if_impl() + ~muxed_zero_copy_if_impl() override { UHD_SAFE_CALL( // Interrupt buffer updater loop @@ -58,7 +58,7 @@ public: _streams.clear();); } - virtual zero_copy_if::sptr make_stream(const uint32_t stream_num) + zero_copy_if::sptr make_stream(const uint32_t stream_num) override { boost::lock_guard<boost::mutex> lock(_mutex); if (_streams.size() >= _max_num_streams) { @@ -75,12 +75,12 @@ public: return stream; } - virtual size_t get_num_dropped_frames() const + size_t get_num_dropped_frames() const override { return _num_dropped_frames; } - void remove_stream(const uint32_t stream_num) + void remove_stream(const uint32_t stream_num) override { boost::lock_guard<boost::mutex> lock(_mutex); _streams.erase(stream_num); @@ -96,12 +96,12 @@ private: public: stream_mrb(size_t size) : _buff(new char[size]) {} - ~stream_mrb() + ~stream_mrb() override { delete[] _buff; } - void release() {} + void release() override {} UHD_INLINE sptr get_new(char* buff, size_t len) { @@ -138,7 +138,7 @@ private: } } - ~stream_impl(void) + ~stream_impl(void) override { // First remove the stream from muxed transport // so no more frames are pushed in @@ -150,17 +150,17 @@ private: } } - size_t get_num_recv_frames(void) const + size_t get_num_recv_frames(void) const override { return _num_recv_frames; } - size_t get_recv_frame_size(void) const + size_t get_recv_frame_size(void) const override { return _recv_frame_size; } - managed_recv_buffer::sptr get_recv_buff(double timeout) + managed_recv_buffer::sptr get_recv_buff(double timeout) override { managed_recv_buffer::sptr buff; if (_buff_queue.pop_with_timed_wait(buff, timeout)) { @@ -177,17 +177,17 @@ private: _buffer_index %= _buffers.size(); } - size_t get_num_send_frames(void) const + size_t get_num_send_frames(void) const override { return _num_send_frames; } - size_t get_send_frame_size(void) const + size_t get_send_frame_size(void) const override { return _send_frame_size; } - managed_send_buffer::sptr get_send_buff(double timeout) + managed_send_buffer::sptr get_send_buff(double timeout) override { return _muxed_xport->base_xport()->get_send_buff(timeout); } |