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 "Lahiru Gunathilake (JIRA)" <ji...@apache.org> on 2008/01/04 05:19:34 UTC

[jira] Created: (AXIS2C-880) Function axis2_svc_client_add_header

Function axis2_svc_client_add_header
------------------------------------

                 Key: AXIS2C-880
                 URL: https://issues.apache.org/jira/browse/AXIS2C-880
             Project: Axis2-C
          Issue Type: Bug
          Components: core/clientapi
    Affects Versions: Current (Nightly)
         Environment: Ubuntu 7.04
            Reporter: Lahiru Gunathilake
             Fix For: Current (Nightly)


<snippet>
AXIS2_EXTERN
axis2_status_t axis2_svc_client_add_header(
      axis2_svc_client_t*   svc_client,
      const axutil_env_t*   env,
      axiom_node_t*         header)
</snippet>

The parameter svc_client does not take responsibility for the memory allocated for header, although it does maintain an internal pointer to the data. This can result in dangling pointer situations if the caller deletes the memory passed using header before svc_client has a chance to remove the header.

Solution: Document memory ownership for parameters and return value.  Investigate the use of pointers in the internal structure to avoid dangling pointer situations.

-- 
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: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


[jira] Assigned: (AXIS2C-880) Function axis2_svc_client_add_header[Alastair FETTES]

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

Dinesh Premalal reassigned AXIS2C-880:
--------------------------------------

    Assignee: Dinesh Premalal

> Function axis2_svc_client_add_header[Alastair FETTES]
> -----------------------------------------------------
>
>                 Key: AXIS2C-880
>                 URL: https://issues.apache.org/jira/browse/AXIS2C-880
>             Project: Axis2-C
>          Issue Type: Bug
>          Components: core/clientapi
>    Affects Versions: Current (Nightly)
>         Environment: Ubuntu 7.04
>            Reporter: Lahiru Gunathilake
>            Assignee: Dinesh Premalal
>             Fix For: Current (Nightly)
>
>         Attachments: diff.txt
>
>
> <snippet>
> AXIS2_EXTERN
> axis2_status_t axis2_svc_client_add_header(
>       axis2_svc_client_t*   svc_client,
>       const axutil_env_t*   env,
>       axiom_node_t*         header)
> </snippet>
> The parameter svc_client does not take responsibility for the memory allocated for header, although it does maintain an internal pointer to the data. This can result in dangling pointer situations if the caller deletes the memory passed using header before svc_client has a chance to remove the header.
> Solution: Document memory ownership for parameters and return value.  Investigate the use of pointers in the internal structure to avoid dangling pointer situations.

-- 
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: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


[jira] Updated: (AXIS2C-880) Function axis2_svc_client_add_header[Alastair FETTES]

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

Senaka Fernando updated AXIS2C-880:
-----------------------------------

    Attachment: diff.txt

Hi all,

Service Client is responsible for the headers added, and we are not enforcing that. Refer diff.txt for proposed patch.

Regards,
Senaka

> Function axis2_svc_client_add_header[Alastair FETTES]
> -----------------------------------------------------
>
>                 Key: AXIS2C-880
>                 URL: https://issues.apache.org/jira/browse/AXIS2C-880
>             Project: Axis2-C
>          Issue Type: Bug
>          Components: core/clientapi
>    Affects Versions: Current (Nightly)
>         Environment: Ubuntu 7.04
>            Reporter: Lahiru Gunathilake
>             Fix For: Current (Nightly)
>
>         Attachments: diff.txt
>
>
> <snippet>
> AXIS2_EXTERN
> axis2_status_t axis2_svc_client_add_header(
>       axis2_svc_client_t*   svc_client,
>       const axutil_env_t*   env,
>       axiom_node_t*         header)
> </snippet>
> The parameter svc_client does not take responsibility for the memory allocated for header, although it does maintain an internal pointer to the data. This can result in dangling pointer situations if the caller deletes the memory passed using header before svc_client has a chance to remove the header.
> Solution: Document memory ownership for parameters and return value.  Investigate the use of pointers in the internal structure to avoid dangling pointer situations.

-- 
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: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


[jira] Resolved: (AXIS2C-880) Function axis2_svc_client_add_header[Alastair FETTES]

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

Dinesh Premalal resolved AXIS2C-880.
------------------------------------

       Resolution: Fixed
    Fix Version/s:     (was: Current (Nightly))
                   1.2.1

patch applied. Thanks Senaka, Alastair and Lahiru for the input.

> Function axis2_svc_client_add_header[Alastair FETTES]
> -----------------------------------------------------
>
>                 Key: AXIS2C-880
>                 URL: https://issues.apache.org/jira/browse/AXIS2C-880
>             Project: Axis2-C
>          Issue Type: Bug
>          Components: core/clientapi
>    Affects Versions: Current (Nightly)
>         Environment: Ubuntu 7.04
>            Reporter: Lahiru Gunathilake
>            Assignee: Dinesh Premalal
>             Fix For: 1.2.1
>
>         Attachments: diff.txt
>
>
> <snippet>
> AXIS2_EXTERN
> axis2_status_t axis2_svc_client_add_header(
>       axis2_svc_client_t*   svc_client,
>       const axutil_env_t*   env,
>       axiom_node_t*         header)
> </snippet>
> The parameter svc_client does not take responsibility for the memory allocated for header, although it does maintain an internal pointer to the data. This can result in dangling pointer situations if the caller deletes the memory passed using header before svc_client has a chance to remove the header.
> Solution: Document memory ownership for parameters and return value.  Investigate the use of pointers in the internal structure to avoid dangling pointer situations.

-- 
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: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org


[jira] Updated: (AXIS2C-880) Function axis2_svc_client_add_header[Alastair FETTES]

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

Lahiru Gunathilake updated AXIS2C-880:
--------------------------------------

    Summary: Function axis2_svc_client_add_header[Alastair FETTES]  (was: Function axis2_svc_client_add_header)

> Function axis2_svc_client_add_header[Alastair FETTES]
> -----------------------------------------------------
>
>                 Key: AXIS2C-880
>                 URL: https://issues.apache.org/jira/browse/AXIS2C-880
>             Project: Axis2-C
>          Issue Type: Bug
>          Components: core/clientapi
>    Affects Versions: Current (Nightly)
>         Environment: Ubuntu 7.04
>            Reporter: Lahiru Gunathilake
>             Fix For: Current (Nightly)
>
>
> <snippet>
> AXIS2_EXTERN
> axis2_status_t axis2_svc_client_add_header(
>       axis2_svc_client_t*   svc_client,
>       const axutil_env_t*   env,
>       axiom_node_t*         header)
> </snippet>
> The parameter svc_client does not take responsibility for the memory allocated for header, although it does maintain an internal pointer to the data. This can result in dangling pointer situations if the caller deletes the memory passed using header before svc_client has a chance to remove the header.
> Solution: Document memory ownership for parameters and return value.  Investigate the use of pointers in the internal structure to avoid dangling pointer situations.

-- 
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: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org