The webrtc objective c sdk includes an extension to the NSString functionality, namely a helper method that converts an NSString to an std::string:
For some reason, when running my application outside of XCode, the above function fails to convert strings and returns them as "!". When running my application inside of XCode, I don't encounter this issue. How is this possible?
The specific point of failure comes when the Ice Servers are being parsed during the Peer Connection initialization, here:
url.stdString is incorrectly returned as "!" :
I can confirm that, if I replace the string conversion with an alternative such as here:
Then I don't hit the error anymore.
Any ideas? I use a debug version of the webrtc lib to print my strings at every point, and I can confirm they exist at every single point, right up to the point where they hit the conversion to std::string, which returns empty strings....
Again, this only reproduces when I run my application file directly; I have no errors when building and running inside of XCode.