opensim-core
                                
                                
                                
                                    opensim-core copied to clipboard
                            
                            
                            
                        Remove setMemomryOwner from the public interface of OpenSim::ArrayPtrs
As explained in https://github.com/opensim-org/opensim-core/issues/3274 and as evident by the list of issues/PRs due to leaks or crashes due to the use of this flag, this is practically giving users a way to shoot themselves in the foot. The proposal here is to:
- Remove the setMemoryOwner from the public interface.
 - Make the code behave as setMemoryOwner is set to true when ownership is the desired behavior
 - Move clients to a container of shared_ptrs when ownership is not the desired behavior (I don't think there're instances of the code where the flag changes during runtime anyway so the flag's correct settings is known on construction.
 - Remove the flag altogether.