I concur. For synchronous calls Marshaller pins variables for the duration
"Alex Yakhnin [MVP]" <a.yakhnin@online.att.net> wrote in message
news:FEA45B91-3793-4A82-BAE7-F08F8BA89439@microsoft.com...
> The Marshaler will probably copy and pin it as long as the native call
> lasts.
> --
> Alex Yakhnin, .NET CF MVP
>
www.intelliprog.com |
www.opennetcf.org >
>
> "Miguel" wrote:
>
>> When invoking the WaitForMultipleObjects function, should the second
>> parameter, which is een array, be pinned? I believe this should be the
>> case, since the CLR could move the array on the managed heap. However,
>> I have never experienced problems when not doing it.
>> Any ideas?
>>
>> DWORD WaitForMultipleObjects(
>> DWORD nCount,
>> CONST HANDLE* lpHandles,
>> BOOL fWaitAll,
>> DWORD dwMilliseconds
>> );
>>
>>
>> In .NET I would use an array of integers or IntPtr.
>>
>>