Inspect the errno argument provided by the callback function.
CURLE_OK (0) as the errno if the request went through okay (see error codes on Wiki). If the request did not go through alright then it should return the corresponding error code for that error.
MTA Client & Server:
Multi Theft Auto v1.5.5-release-13959
Initially committed here: #271 (comment)
Will create a new PR for this.
The text was updated successfully, but these errors were encountered:
* curl: update from 7.59.0 to 7.61.0
* curl: update premake5
* curl: fix gcc compile errors
* curl: fix gcc compile errors, part 2
* curl: fix gcc compile errors, part 3
* CRemoteCalls: set application/json Content-Type
* CRemoteCalls: return errno as 0 instead of nil if JSON was valid
* CRemoteCalls: addendum to previous commit, let's return 0 always
The reason is that the request went through and everything, it should be considered as OK instead of nil upon
success. Yes, the JSON might be invalid, but then responseData is nil, and that's ok.
* curl: revert configure and Makefile changes
* curl: revert autocrlf changes to ease diff
My Windows PC Git did autocrlf which caused changes to almost all the files, lol
* CRemoteCalls: revert change to callRemote errno behavior, see #294