projects
/
collectd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
924c9af
)
src/daemon/common.c: Fix off-by-one error in escape_slashes().
author
Florian Forster
<octo@collectd.org>
Sun, 28 Jun 2015 12:05:05 +0000
(14:05 +0200)
committer
Florian Forster
<octo@collectd.org>
Sun, 28 Jun 2015 12:09:10 +0000
(14:09 +0200)
Partial cherry-pick of
0cba91923be9326224f8434e4aae7691f7b6dad1
.
src/common.c
patch
|
blob
|
history
diff --git
a/src/common.c
b/src/common.c
index
f41e950
..
c284942
100644
(file)
--- a/
src/common.c
+++ b/
src/common.c
@@
-445,7
+445,7
@@
int escape_slashes (char *buf, int buf_len)
if (buf[0] == '/')
memmove (buf, buf + 1, buf_len - 1);
- for (i = 0; i < buf_len
- 1
; i++)
+ for (i = 0; i < buf_len; i++)
{
if (buf[i] == '\0')
break;