Skip to content

Commit

Permalink
DCTFilter/DCTFilter.cpp: use std::lock_guard
Browse files Browse the repository at this point in the history
  • Loading branch information
WolframRhodium committed May 19, 2022
1 parent 8a909ce commit 9962547
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions DCTFilter/DCTFilter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ static const VSFrameRef *VS_CC dctfilterGetFrame(int n, int activationReason, vo
throw std::string{ "malloc failure (buffer)" };

{
std::scoped_lock<std::shared_mutex> l(d->buffer_lock);
std::lock_guard<std::shared_mutex> l(d->buffer_lock);
d->buffer.emplace(threadId, buffer);
}
}
Expand Down Expand Up @@ -267,7 +267,7 @@ static void VS_CC dctfilterCreate(const VSMap *in, VSMap *out, void *userData, V
}
}

d->qps.resize(d->n * d->n, 0);
d->qps.resize(d->n * d->n);
const int nqps = vsapi->propNumElements(in, "qps");
if (nqps > 0) {
const double * qps = vsapi->propGetFloatArray(in, "qps", nullptr);
Expand Down

0 comments on commit 9962547

Please sign in to comment.