Hey Neale, What makes a short ref suitable to be moved during GC?
I am confused, I thought we wouldn't do that. Miguel On Thu, Aug 21, 2014 at 6:58 PM, Neale Ferguson <[email protected]> wrote: > I've been looking at OciDefineHandle and the OciDefineByPos call it uses > in particular. Currently two of the parameters passed to this call are > short variables. They are passed as "ref" fields as Oracle uses their > address to put size and indicator data once the data is fetched. However, > being defined as short means that they are eligible for being moved during > garbage collection. Thus if that field is moved between the OciDefineByPos > call and the fetch of the data then what Oracle is pointing to may no > longer be variable. I'm thinking it may be better to define these fields as > IntPtr and allocate them and retrieve their values via Marshal.ReadInt16. > I'm currently testing these changes and so far I'm not getting the failures > I had been encountering. If this is a valid analysis then the OciBindxxxx > calls will also need attention as it uses a ref indp parameter as well - > these appear to be used in OracleParameter.cs. > > Neale > _______________________________________________ > Mono-devel-list mailing list > [email protected] > http://lists.ximian.com/mailman/listinfo/mono-devel-list >
_______________________________________________ Mono-devel-list mailing list [email protected] http://lists.ximian.com/mailman/listinfo/mono-devel-list
