Skip to content

Commit

Permalink
tidy: Remove an ineffective cast.
Browse files Browse the repository at this point in the history
Clang-tidy pointed out a location where a 32-bit integer is being cast
to a 64bit size_t.  This cast is unnecessary and will be done
implicitly by the compiler.

https://clang.llvm.org/extra/clang-tidy/checks/bugprone-misplaced-widening-cast.html
  • Loading branch information
linuxdude42 committed Dec 6, 2019
1 parent eaa06c1 commit 83d6acf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mythtv/libs/libmythtv/mythdeinterlacer.cpp
Expand Up @@ -146,7 +146,7 @@ void MythDeinterlacer::Filter(VideoFrame *Frame, FrameScanType Scan)
if (!m_bobFrame->buf || (m_bobFrame->size != Frame->size))
{
av_free(m_bobFrame->buf);
m_bobFrame->buf = static_cast<unsigned char*>(av_malloc(static_cast<size_t>(Frame->size + 64)));
m_bobFrame->buf = static_cast<unsigned char*>(av_malloc(Frame->size + 64));
m_bobFrame->size = Frame->size;
}

Expand Down

0 comments on commit 83d6acf

Please sign in to comment.