I did further investigations:
I changed the code and used libcurl directly.
With very strange results.
First I declared a constant for the authcode, since it is fixed in my application.
Code:
*headers = curl_slist_append(*headers, "X-Auth-Token: " + #X_Auth_Token$)
It fails in the same way.
The I thought: may be the string buffer is not avalaible when it is needed
and I used an extra variable.
Code:
Token$ = "X-Auth-Token: " + #X_Auth_Token$
*headers = curl_slist_append(*headers, Token$)
It fails in the same way.
Only working version:
Code:
*headers = curl_slist_append(*headers, "X-Auth-Token: 123456"
I use
Code:
curl_slist_append(slist.i, string.p-utf8)
for the import.
So 2 possibilities:
1. Something with p-utf8 is not 100% Ok
2. A bug in libcurls curl_slist_append()
I searched in the web for 2. but I found no informations about a bug.
Also a curl.exe request works as expected (Ok, there is also the complete string at once provided)
I have no chance to go deeper inside.
Bernd