mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-04 06:29:31 +00:00
NULL-terminate PyMethodDef array
PyMethodDef arrays are supposed to end with an entry full of NULL/0 values. This is missing in gst-python in the file gstmodule.c. This causes out of bounds memory reads which can be seen / tested by compiling gst-python with address sanitizer (-fsanitize=address in CFLAGS/LDFLAGS). https://bugzilla.gnome.org/show_bug.cgi?id=762766
This commit is contained in:
parent
b2077dcfab
commit
58c324e0cc
1 changed files with 2 additions and 1 deletions
|
@ -368,7 +368,8 @@ static PyMethodDef _gi_gst_functions[] = {
|
||||||
{"fixme", (PyCFunction) _wrap_gst_fixme, METH_VARARGS,
|
{"fixme", (PyCFunction) _wrap_gst_fixme, METH_VARARGS,
|
||||||
NULL},
|
NULL},
|
||||||
{"memdump", (PyCFunction) _wrap_gst_memdump, METH_VARARGS,
|
{"memdump", (PyCFunction) _wrap_gst_memdump, METH_VARARGS,
|
||||||
NULL}
|
NULL},
|
||||||
|
{NULL, NULL, 0, NULL}
|
||||||
};
|
};
|
||||||
|
|
||||||
PYGLIB_MODULE_START (_gi_gst, "_gi_gst")
|
PYGLIB_MODULE_START (_gi_gst, "_gi_gst")
|
||||||
|
|
Loading…
Reference in a new issue