summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDoug Bailey <dbailey@digium.com>2009-02-18 16:09:12 +0000
committerDoug Bailey <dbailey@digium.com>2009-02-18 16:09:12 +0000
commitfa3dec169b5dd7da5d0a61d49fa296c020137f9d (patch)
tree16d484dae61b727d6d8e968aa5fced41e9293088
parent0fe1df19df4fe7ca4834b8ee6f07414648f51810 (diff)
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/trunk@176948 65c4cc65-6c06-0410-ace0-fbb531ad65f3
-rw-r--r--main/utils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/main/utils.c b/main/utils.c
index 3a5028979..a19ed900f 100644
--- a/main/utils.c
+++ b/main/utils.c
@@ -1600,7 +1600,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;