openh264: memcmp return value 0 means match

Commit e2aa76db79 introduced version
check guard for OpenH264 binary. There was a boolean error in
memcmp so matching OpenH264 was erroneously rejected.
Fixes #1278

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1219>
This commit is contained in:
Seppo Yli-Olli 2020-04-27 11:43:57 +03:00 committed by GStreamer Merge Bot
parent 851557af20
commit 90f374dd0c

View file

@ -47,7 +47,7 @@ plugin_init (GstPlugin * plugin)
* ABI without changing the SONAME.
*/
OpenH264Version libver = WelsGetCodecVersion ();
if (memcmp (&libver, &g_stCodecVersion, sizeof (libver))) {
if (memcmp (&libver, &g_stCodecVersion, sizeof (libver)) == 0) {
gst_element_register (plugin, "openh264dec", GST_RANK_MARGINAL,
GST_TYPE_OPENH264DEC);
gst_element_register (plugin, "openh264enc", GST_RANK_MARGINAL,