Re: pgsql: Add pg_strnlen() a portable implementation of strlen.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Add pg_strnlen() a portable implementation of strlen.
Date: 2017-10-10 22:10:15
Message-ID: 31930.1507673415@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

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

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Andres Freund 2017-10-10 22:38:28 pgsql: Rewrite strnlen replacement implementation from 8a241792f96.
Previous Message Andres Freund 2017-10-10 21:59:50 Re: pgsql: Add pg_strnlen() a portable implementation of strlen.