axis-c-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Samisa Abeysinghe (JIRA)" <j...@apache.org>
Subject [jira] Commented: (AXIS2C-474) Use pointer plus length instead of nul-terminated string for text content
Date Wed, 20 Dec 2006 09:52:21 GMT
    [ http://issues.apache.org/jira/browse/AXIS2C-474?page=comments#action_12459873 ] 
            
Samisa Abeysinghe commented on AXIS2C-474:
------------------------------------------

I guess the advantage is the reduced number of calls to strlen. Is there any other rationale
for your suggestion. 



> Use pointer plus length instead of nul-terminated string for text content
> -------------------------------------------------------------------------
>
>                 Key: AXIS2C-474
>                 URL: http://issues.apache.org/jira/browse/AXIS2C-474
>             Project: Axis2-C
>          Issue Type: Improvement
>          Components: xml/om
>    Affects Versions: Current (Nightly)
>            Reporter: James Clark
>            Priority: Minor
>
> Nul-terminated strings are fine for short strings, but for potentially long strings,
it's better to use a pointer plus a length.  (Sometimes it's good to nul-terminate it as well
as providing a length.)  One case where I would in particular suggest using a length is for
axiom_text.  At the same time, other functions that deal with XML text content (such as axiom_xml_writer::write_characters)
should also be fixed.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

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


Mime
View raw message