On 12/15/2009 06:13 AM, [email protected] wrote:
True.

But, after  curl_easy_perform() is called, how do I know which out of
the following lines didn't actually work? Was there any problem with
CURLOPT_POSTFIELDS or the connection with
http://10.31.251.161:5985/wsman was not established or  it didn't accept
strHttpContent.c_str() etc.

*       curl_easy_setopt(mCurl,
CURLOPT_POSTFIELDS,"user=administrator&pas=coll...@234")
*       curl_easy_setopt(mCurl, CURLOPT_URL,
"http://10.31.251.161:5985/wsman";)
*       curl_easy_setopt(mCurl, CURLOPT_POST, 1)
*       curl_easy_setopt(mCurl, CURLOPT_POSTFIELDS,
strHttpContent.c_str())
*       curl_easy_setopt(mCurl, CURLOPT_POSTFIELDSIZE,
strHttpContent.length())

curl_easy_perform(mCurl)
                
Hi Nitin,

Add this line to your code after curl_easy_init();

curl_easy_setopt(mCurl, CURLOPT_VERBOSE, TRUE);

This will help you know what happens at every level. Its like debugging.


regards,
Isaac
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html

Reply via email to