projects
/
asterisk/asterisk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e9184b8
)
Use memmove() instead of memcpy() for a case where the buffers overlap.
author
Russell Bryant
<russell@russellbryant.com>
Mon, 8 Feb 2010 23:23:45 +0000
(23:23 +0000)
committer
Russell Bryant
<russell@russellbryant.com>
Mon, 8 Feb 2010 23:23:45 +0000
(23:23 +0000)
Once again, valgrind is freaking awesome. That is all.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@245610
65c4cc65
-6c06-0410-ace0-
fbb531ad65f3
main/pbx.c
patch
|
blob
|
history
diff --git
a/main/pbx.c
b/main/pbx.c
index
3b3b1cd
..
6a36f43
100644
(file)
--- a/
main/pbx.c
+++ b/
main/pbx.c
@@
-2927,7
+2927,7
@@
static const char *ast_str_substring(struct ast_str *value, int offset, int leng
if (offset > 0) {
/* Go ahead and chop off the beginning */
- memcpy(ast_str_buffer(value), ast_str_buffer(value) + offset, ast_str_strlen(value) - offset + 1);
+ memmove(ast_str_buffer(value), ast_str_buffer(value) + offset, ast_str_strlen(value) - offset + 1);
lr -= offset;
}