gnu-octave / symbolic

A Symbolic Package for Octave using SymPy
https://octave.sourceforge.io/symbolic/
GNU General Public License v3.0
152 stars 36 forks source link

private/python_ipc_popen2: Fixes warning after unloading package. #1174

Closed alexvong243f closed 2 years ago

alexvong243f commented 2 years ago

This warning

--8<---------------cut here---------------start------------->8--- warning: onCleanup: error caught while executing cleanup function: 'python_ipc_popen2_reset' undefined near line 78, column 30 "'python_ipc_popen2_reset' undefined" --8<---------------cut here---------------end--------------->8---

is caused by "pkg unload symbolic".

We fix it by closing file descriptors and waitpid directly in the cleanup function instead of using private/python_ipc_popen2_reset.

Fixes #1160.