Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e22jH-0001Hx-Mv for pgsql-committers@arkaria.postgresql.org; Tue, 10 Oct 2017 22:10:23 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1e22jH-0003FI-6r for pgsql-committers@arkaria.postgresql.org; Tue, 10 Oct 2017 22:10:23 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e22jG-0003ED-Vs for pgsql-committers@postgresql.org; Tue, 10 Oct 2017 22:10:23 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e22jE-0006pC-4a for pgsql-committers@postgresql.org; Tue, 10 Oct 2017 22:10:22 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id v9AMAFkg031931; Tue, 10 Oct 2017 18:10:15 -0400 From: Tom Lane To: Andres Freund cc: Andrew Dunstan , pgsql-committers@postgresql.org Subject: Re: pgsql: Add pg_strnlen() a portable implementation of strlen. In-reply-to: <20171010215618.qbracvhslzvuxilv@alap3.anarazel.de> References: <20171009231509.nlptgdrtg2au6frn@alap3.anarazel.de> <44745881-6095-e3ba-e8eb-23b1d92bffab@dunslane.net> <20171010194818.p2hhod32ezmvhryb@alap3.anarazel.de> <21912.1507668699@sss.pgh.pa.us> <20171010205315.g7l6tf3j5jzplqax@alap3.anarazel.de> <20171010215618.qbracvhslzvuxilv@alap3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Tue, 10 Oct 2017 14:56:18 -0700" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <31929.1507673415.1@sss.pgh.pa.us> Date: Tue, 10 Oct 2017 18:10:15 -0400 Message-ID: <31930.1507673415@sss.pgh.pa.us> List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-committers Precedence: bulk Sender: pgsql-committers-owner@postgresql.org Andres Freund 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 -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers