You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by "Robert Schweikert (JIRA)" <ji...@apache.org> on 2011/01/03 22:41:46 UTC

[jira] Created: (AXIS2C-1522) Enabling curl support triggers build error - Code issue may trigger memory corruption

Enabling curl support triggers build error - Code issue may trigger memory corruption
-------------------------------------------------------------------------------------

                 Key: AXIS2C-1522
                 URL: https://issues.apache.org/jira/browse/AXIS2C-1522
             Project: Axis2-C
          Issue Type: Bug
          Components: core/transport
    Affects Versions: 1.6.0
         Environment: openSUSE 11.3
turn warnings into errors
            Reporter: Robert Schweikert


Using configure --enable-libcurl triggers the following compile errors when warnings are turned into errors at compile time:

libcurl/axis2_libcurl.c: In function 'axis2_libcurl_send':
libcurl/axis2_libcurl.c:114:19: error: 'content_type' may be used uninitialized in this function

libcurl/axis2_libcurl.c: In function 'axis2_libcurl_send':
libcurl/axis2_libcurl.c:143:5: error: call to '_curl_easy_setopt_err_error_buffer' declared with attribute warning: curl_easy_setopt expects a char buffer of CURL_ERROR_SIZE as argument for this option

While the first error is harmless as 'content_type' is not used in an uninitialized fashion, the second error has the potential to trigger memory corruption if an error occurs. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: c-dev-help@axis.apache.org


[jira] [Resolved] (AXIS2C-1522) Enabling curl support triggers build error - Code issue may trigger memory corruption

Posted by "Samisa Abeysinghe (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AXIS2C-1522?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Samisa Abeysinghe resolved AXIS2C-1522.
---------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.7.0
         Assignee: Samisa Abeysinghe

Half the patch was already there. Applied the other half. 

Committed revision 1163208.

> Enabling curl support triggers build error - Code issue may trigger memory corruption
> -------------------------------------------------------------------------------------
>
>                 Key: AXIS2C-1522
>                 URL: https://issues.apache.org/jira/browse/AXIS2C-1522
>             Project: Axis2-C
>          Issue Type: Bug
>          Components: core/transport
>    Affects Versions: 1.6.0
>         Environment: openSUSE 11.3
> turn warnings into errors
>            Reporter: Robert Schweikert
>            Assignee: Samisa Abeysinghe
>             Fix For: 1.7.0
>
>         Attachments: axis2c_initBuffer_curl.patch
>
>
> Using configure --enable-libcurl triggers the following compile errors when warnings are turned into errors at compile time:
> libcurl/axis2_libcurl.c: In function 'axis2_libcurl_send':
> libcurl/axis2_libcurl.c:114:19: error: 'content_type' may be used uninitialized in this function
> libcurl/axis2_libcurl.c: In function 'axis2_libcurl_send':
> libcurl/axis2_libcurl.c:143:5: error: call to '_curl_easy_setopt_err_error_buffer' declared with attribute warning: curl_easy_setopt expects a char buffer of CURL_ERROR_SIZE as argument for this option
> While the first error is harmless as 'content_type' is not used in an uninitialized fashion, the second error has the potential to trigger memory corruption if an error occurs. 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: c-dev-help@axis.apache.org


[jira] Updated: (AXIS2C-1522) Enabling curl support triggers build error - Code issue may trigger memory corruption

Posted by "Robert Schweikert (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AXIS2C-1522?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Robert Schweikert updated AXIS2C-1522:
--------------------------------------

    Attachment: axis2c_initBuffer_curl.patch

The attached patch fixes both problems by 
a.) initializing the 'content_type' pointer
b.) remove the & operator

> Enabling curl support triggers build error - Code issue may trigger memory corruption
> -------------------------------------------------------------------------------------
>
>                 Key: AXIS2C-1522
>                 URL: https://issues.apache.org/jira/browse/AXIS2C-1522
>             Project: Axis2-C
>          Issue Type: Bug
>          Components: core/transport
>    Affects Versions: 1.6.0
>         Environment: openSUSE 11.3
> turn warnings into errors
>            Reporter: Robert Schweikert
>         Attachments: axis2c_initBuffer_curl.patch
>
>
> Using configure --enable-libcurl triggers the following compile errors when warnings are turned into errors at compile time:
> libcurl/axis2_libcurl.c: In function 'axis2_libcurl_send':
> libcurl/axis2_libcurl.c:114:19: error: 'content_type' may be used uninitialized in this function
> libcurl/axis2_libcurl.c: In function 'axis2_libcurl_send':
> libcurl/axis2_libcurl.c:143:5: error: call to '_curl_easy_setopt_err_error_buffer' declared with attribute warning: curl_easy_setopt expects a char buffer of CURL_ERROR_SIZE as argument for this option
> While the first error is harmless as 'content_type' is not used in an uninitialized fashion, the second error has the potential to trigger memory corruption if an error occurs. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: c-dev-help@axis.apache.org