Chad,

In this case "[MarshalAs(UnmanagedType.LPWStr)] ref/out string" will work, 
because the runtime frees the string memory with CoTaskMemFree() by 
default, and FindMimeFromData() allocates it with CoTaskMemAlloc().

If you for some reason want to use an IntPtr parameter instead, free the 
memory with Marshal.FreeCoTaskMem().


Mattias

===
Mattias Sjögren
[EMAIL PROTECTED]

You can read messages from the Advanced DOTNET archive, unsubscribe from Advanced 
DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.

Reply via email to