Exception thrown on trying to instantiate http_client

218 views Asked by At

I'm trying to run a simple example with http_client, using CppRestSDK 2.10 (Casablanca) but on trying to create the http_client instance, it crashes with the exception in the attached image.

The line of code that triggers the exception is -

http_client client(U("https://jsonplaceholder.typicode.com/photos"));

That's the first line in main()

CppRestSDK was installed using vcpkg install cpprestsdk:x64-windows

Please help...

enter image description here

1

There are 1 answers

0
user2049945 On

OK, found it, I apparently was trying to link release lib to my debug build.

Thanks go to https://github.com/Microsoft/cpprestsdk/issues/694