Closed marioalexis84 closed 1 year ago
Thank you @marioalexis84 👍, as I do not understand a lot what is going on here, maybe @wwmayer can review this.
FYI, I've applied this patch on pivy and used it with FreeCAD 20.1: a lot more integrated tests passing now (via FreeCAD -t 0
)
If the macro
PY_SSIZE_T_CLEAN
is defined (mandatory in Python 3.10), when parsing arguments with#
variants of formats (s#
,y#,
etc.) the type of the length argument must bePy_ssize_t
. This is related to https://github.com/coin3d/pivy/pull/91. The problem is not due to what is described in #91, but to the type of the argument. The implementation proposed in #91 for the functionscast
andcast_internal
only fix the crash in those cases when onlycast_internal
is used, butcast
still crash, for example. when creating the quarter widget.To reproduce the crash:
But most important: