On 2023-04-08 15:08, Paul Eggert wrote: > the overlapping move constraint doesn't apply to the null > terminator. Oh, sorry, scratch that: it does apply, because of the 'restrict' constraints on the argument pointers. Hence (contrary to my previous assertion) PATCH 1/2's code does conform to draft POSIX. However, it's still worrisome that PATCH 1/2's behavior disagrees with OpenBSD's for some nonconforming calls. If the main point of the patch is compatibility, surely it is better to be compatible with existing practice, not merely with draft POSIX. Anyway, please ignore the documentation patch I sent yesterday in this thread, and look instead at the attached. This is the same patch, except with fixed wording under strlcpy and strlcat as to whether behavior is undefined.