If Libevent uses strcpy, even safely, it seems OpenBSD's linker will
complain every time a library links Libevent. It's easier just not to
use the old thing, even when it's safe to do so.
}
for (i = 0; i < old_size; ++i) {
const char *replaced = html_replace(html[i], scratch_space);
- /* this is length checked */
- strcpy(p, replaced);
- p += strlen(replaced);
+ size_t len = strlen(replaced);
+ memcpy(p, replaced, len);
+ p += len;
}
*p = '\0';