Raise an error if creating an unknown xwidget type

* src/xwidget.c (Fmake_xwidget): Error if TYPE is invalid (bug#51682).
This commit is contained in:
Po Lu 2021-11-09 05:03:47 +01:00 committed by Lars Ingebrigtsen
parent 394f6b9167
commit b5efdccefb

View file

@ -128,6 +128,9 @@ fails. */)
CHECK_FIXNAT (width);
CHECK_FIXNAT (height);
if (!EQ (type, Qwebkit))
error ("Bad xwidget type");
struct xwidget *xw = allocate_xwidget ();
Lisp_Object val;
xw->type = type;