projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Merge branch 'collectd-4.5' into collectd-4.6
[collectd.git]
/
src
/
utils_subst.c
diff --git
a/src/utils_subst.c
b/src/utils_subst.c
index
640007c
..
a49f6db
100644
(file)
--- a/
src/utils_subst.c
+++ b/
src/utils_subst.c
@@
-37,7
+37,8
@@
char *subst (char *buf, size_t buflen, const char *string, int off1, int off2,
|| (NULL == replacement))
return NULL;
- sstrncpy (buf_ptr, string, (off1 + 1 > buflen) ? buflen : off1 + 1);
+ sstrncpy (buf_ptr, string,
+ ((size_t)off1 + 1 > buflen) ? buflen : (size_t)off1 + 1);
buf_ptr += off1;
len -= off1;