mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-31 22:25:38 -04:00
libcamera: remove unused buffer variable in LibCamera::stop()
To fix build warning about a variable being unused in LibCamera::stop():
[1/2] Compiling C++ object spa/plugins/libcamera/libspa-libcamera.so.p/libcamera_wrapper.cpp.o
../spa/plugins/libcamera/libcamera_wrapper.cpp: In member function ‘void LibCamera::stop()’:
../spa/plugins/libcamera/libcamera_wrapper.cpp:531:58: warning: unused variable ‘buffer’ [-Wunused-variable]
531 | for (const std::unique_ptr<FrameBuffer> &buffer : this->allocator_->buffers(stream)) {
| ^~~~~~
This commit is contained in:
parent
5471a0018b
commit
76cb5c1169
1 changed files with 2 additions and 3 deletions
|
|
@ -524,13 +524,12 @@ extern "C" {
|
|||
void LibCamera::stop() {
|
||||
this->disconnect();
|
||||
|
||||
uint32_t bufIdx = 0;
|
||||
StreamConfiguration &cfg = this->config_->at(0);
|
||||
Stream *stream = cfg.stream();
|
||||
uint32_t nbuffers = this->allocator_->buffers(stream).size();
|
||||
|
||||
for (const std::unique_ptr<FrameBuffer> &buffer : this->allocator_->buffers(stream)) {
|
||||
for (uint32_t bufIdx = 0; bufIdx < nbuffers; bufIdx++) {
|
||||
delete [] this->fd_[bufIdx];
|
||||
bufIdx++;
|
||||
}
|
||||
delete [] this->fd_;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue