Strange that this should be needed; the SET_SVAL() on the line below ought to have the same effect (during normal circumstances where sizeof(void *) == sizeof(INT_TYPE)). What are the sizes for the
Well, you are right. My fix was a no-op. However, several coredumps and valgrind runs later, I found and fixed two things:
commit 5884c9d61d11a8374e2feac0e4f211121468aea8 Author: Stephen R. van den Berg srb@cuci.nl Date: Sun Jul 19 23:55:26 2020 +0200
Stdio.Buffer: Protect against calls in destructed Buffer objects.
src/modules/_Stdio/buffer.cmod | 272 ++++++++++++++++++++++++------------------- 1 file changed, 149 insertions(+), 123 deletions(-)
commit 01543a00e48294140995709915891d7f7745bdb2 Author: Stephen R. van den Berg srb@cuci.nl Date: Mon Jul 6 03:40:03 2020 +0200
Stdio.Buffer: Check for PIKE_T_FUNCTION before acting on objects.
src/modules/_Stdio/buffer.cmod | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-)
Both caused segmentation faults. Mostly because the buffer.cmod code is not good with asynchronously destructed objects. These changes should be backported to Pike 8.0. I tried, but that is slightly non-trivial at some points. If someone else wants to give it a try, be my guest!