Merged revisions 176948 via svnmerge from

https://origsvn.digium.com/svn/asterisk/trunk

........
  r176948 | dbailey | 2009-02-18 10:09:12 -0600 (Wed, 18 Feb 2009) | 2 lines
  
  Need to take into account the \0 terminator of the old string to determine the amount available.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.0@177004 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Doug Bailey
2009-02-18 16:30:15 +00:00
parent babd94b38e
commit 20dea27b4b

View File

@@ -1493,7 +1493,7 @@ void __ast_string_field_ptr_build_va(struct ast_string_field_mgr *mgr,
*/
if ((*ptr)[0] != '0') {
target = (char *) *ptr;
available = strlen(target);
available = strlen(target) + 1;
} else {
target = (*pool_head)->base + mgr->used;
available = space;