diff --git a/src/elogd.c b/src/elogd.c index 861e8a9c..6ebba386 100755 --- a/src/elogd.c +++ b/src/elogd.c @@ -15703,7 +15703,7 @@ void build_ref(char *ref, int size, char *mode, char *expand, char *attach, char /* replace any '&' by '&' */ strlcpy(str, ref, sizeof(str)); - strencode2(ref, str, sizeof(ref)); + strencode2(ref, str, size); } /*------------------------------------------------------------------*/