Andres Freund <andres(at)anarazel(dot)de> writes:
> Here's a fix. Not quite sure whether we really need the
> HAVE_DECL_STRNLEN test, added it for symmetry.
LGTM. I think the DECL test is a good idea; the system definition
might be a macro or otherwise weird, in which case we'd cause problems
if we write an extern definition anyway.
regards, tom lane