Open anders9ustafsson opened 5 years ago
On a similar note, using Marshal.PtrToStringAuto
appears to cause problems when appying the C# wrapper in a Windows Desktop application (yes, I am aware that this is not a supported scenario, but generally it works). Marshalling yields strings in Chinese. Marshal.PtrToStringAnsi
seems to produce more correct results, at least when running on an en-US localized computer. The change does not appear to break anything for the other platforms either.
The
ProxyConfig.Routes
setter in the C# wrapper fails to conserve the strings provided by the user in an iOS application, subsequently resulting in failure to sufficiently establish media transfer when making a call.Problem appears to be that the
ProxyConfig.Routes
setter is using the static methodStringArrayToBctbxList
to convert managed strings to unmanaged. On Android conversion seems to work, but on iOS the unmanaged string is completely distorted. Changing this line:bctbx_list = bctbx_list_append(bctbx_list, s);
into this
bctbx_list = bctbx_list_append(bctbx_list, Marshal.StringToHGlobalAnsi(s));
does seem to help though.