axis-c-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dami...@apache.org
Subject svn commit: r958471 - /axis/axis2/c/core/trunk/src/core/transport/http/sender/libcurl/axis2_libcurl.c
Date Mon, 28 Jun 2010 06:21:51 GMT
Author: damitha
Date: Mon Jun 28 06:21:51 2010
New Revision: 958471

URL: http://svn.apache.org/viewvc?rev=958471&view=rev
Log:
Applying patch in AXIS2C-1372

Modified:
    axis/axis2/c/core/trunk/src/core/transport/http/sender/libcurl/axis2_libcurl.c

Modified: axis/axis2/c/core/trunk/src/core/transport/http/sender/libcurl/axis2_libcurl.c
URL: http://svn.apache.org/viewvc/axis/axis2/c/core/trunk/src/core/transport/http/sender/libcurl/axis2_libcurl.c?rev=958471&r1=958470&r2=958471&view=diff
==============================================================================
--- axis/axis2/c/core/trunk/src/core/transport/http/sender/libcurl/axis2_libcurl.c (original)
+++ axis/axis2/c/core/trunk/src/core/transport/http/sender/libcurl/axis2_libcurl.c Mon Jun
28 06:21:51 2010
@@ -441,12 +441,21 @@ axis2_libcurl_send(
         else
         buffer_size = output_stream_size;
         {
-            char tmp_buf[10];
+            /*
+             * Curl calculates the content-length automatically.
+             * This commented section is not only unnecessary,
+             * it interferes with authentication.
+             *
+             * NTLM, for example, will send an empty request
+             * first (no body) to get the auth challenge
+             * before resending with actual content.
+             */
+            /*char tmp_buf[10];
             sprintf(tmp_buf, "%d", buffer_size);
             tmp_strcat = axutil_stracat(env, content_len, tmp_buf);
             headers = curl_slist_append(headers, tmp_strcat);
             AXIS2_FREE(env->allocator, tmp_strcat);
-            tmp_strcat = NULL;
+            tmp_strcat = NULL;*/
 
             tmp_strcat = axutil_stracat(env, content, content_type);
             headers = curl_slist_append(headers, tmp_strcat);



Mime
View raw message