The bug has always exited, but the symptoms of the bug were brought about by the update to wxWidgets 3.1.0, which changed the implementation of wxString enough so the prodedure body that was read from the mini-editor would be freed before its buffer was copied into the reader. The fix is to hold a reference to the wxString while its internal buffer is being used.