You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by xe...@xml.apache.org on 2004/08/30 21:08:19 UTC
[jira] Commented: (XERCESC-1206) IconvGNU transcoder returns char arrays starting with \0
The following comment has been added to this issue:
Author: HAUTION Philippe
Created: Mon, 30 Aug 2004 12:07 PM
Body:
The fix is OK for me.
Thanks,
PH
---------------------------------------------------------------------
View this comment:
http://issues.apache.org/jira/browse/XERCESC-1206?page=comments#action_37928
---------------------------------------------------------------------
View the issue:
http://issues.apache.org/jira/browse/XERCESC-1206
Here is an overview of the issue:
---------------------------------------------------------------------
Key: XERCESC-1206
Summary: IconvGNU transcoder returns char arrays starting with \0
Type: Bug
Status: Resolved
Priority: Major
Resolution: FIXED
Project: Xerces-C++
Components:
Utilities
Versions:
2.5.0
Assignee:
Reporter: HAUTION Philippe
Created: Mon, 10 May 2004 4:12 AM
Updated: Mon, 30 Aug 2004 12:07 PM
Environment: Linux 2.4.25-1-686 gcc 3.2.2
Description:
The utility method in IconvGNUTransService.cpp :
bool
IconvGNULCPTranscoder::transcode(const XMLCh* const toTranscode,
char* const toFill,
const unsigned int maxBytes,
MemoryManager* const manager)
ends with : toFill[rc] = 0;
where rc happens to be :
size_t rc = iconvTo(wideCharBuf, &len, &ptr, maxBytes);
So if everything went OK, rc equals 0 and therefore the first character of toFill will be \0.
---------------------------------------------------------------------
JIRA INFORMATION:
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
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org