I have the following function in a C++ DLL
extern \"C\" __declspec(dllexport) bool Exist(const char* name)
{
//if (g_Queues.find(name) != g_Queues.end())
/
Perhaps marshaling the argument of the function might help:
[MarshalAs(UnmanagedType.LPStr)]
Here is how the declaration should look like:
[DllImport("Whisper.dll", EntryPoint="Exist", CallingConvention=CallingConvention.Cdecl)]
public static extern bool Exist([MarshalAs(UnmanagedType.LPStr)] string name);