> Please use xstrlcpy.

That's not necessary here, as far as I can see `event` is not a c string but a binary string (not necesarily NULL-terminated). But even if it was NULL-terminated, it wouldn't be efficient to use `xstrlcpy` as that would perform `strlen` which we already have (`event.size`). Ideally, we'd be able to write:

```c
char e[EVENT_MAXLEN + 1];
(x)mempcpy(e, event.data, min(EVENT_MAXLEN, length)) = NUL;
```