If wxSizerItem passed to Replace() contains a window, the window must be associated with the sizer to ensure that it is uncoupled from it when it is destroyed. Add a simple test which resulted in a use-after-free before but passes now.
If wxSizerItem passed to Replace() contains a window, the window must be associated with the sizer to ensure that it is uncoupled from it when it is destroyed. Add a simple test which resulted in a use-after-free before but passes now.