Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1erBI2-00056n-ID for pgsql-bugs@arkaria.postgresql.org; Wed, 28 Feb 2018 23:37:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1erBI0-0003jo-W2 for pgsql-bugs@arkaria.postgresql.org; Wed, 28 Feb 2018 23:37:36 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1erBI0-0003iO-MV for pgsql-bugs@lists.postgresql.org; Wed, 28 Feb 2018 23:37:36 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1erBHy-0006Bg-0M for pgsql-bugs@postgresql.org; Wed, 28 Feb 2018 23:37:35 +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 w1SNbR5M009304; Wed, 28 Feb 2018 18:37:27 -0500 From: Tom Lane To: Michael Paquier cc: Postgres bugs , Rainer Orth Subject: Re: Conflicting declarations for b64_encode etc. on Solaris 11.4 Beta In-reply-to: <20180214060454.GA4544@paquier.xyz> References: <20180124015251.GA14001@paquier.xyz> <20180214060454.GA4544@paquier.xyz> Comments: In-reply-to Michael Paquier message dated "Wed, 14 Feb 2018 15:04:54 +0900" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <9302.1519861047.1@sss.pgh.pa.us> Date: Wed, 28 Feb 2018 18:37:27 -0500 Message-ID: <9303.1519861047@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Michael Paquier writes: > Attached is an updated patch which does a bit more consistency work. I > have renamed the base64 functions with pg_base64_ as prefix in encode.c, > to avoid any conflicts in encode.c. pgp-armor.c also gets the same > treatment. There is no real point in renaming the other functions is > not necessary, and hex_encode/hex_decode are publicly available, so > renaming them would cause breakage for any callers of them in plugins. Pushed. > It is a bit sad that both pgcrypto and encode.c hold copies of base64 > functions. And on top of that, there's src/common/base64.c with again almost the same functionality. But refactoring to fix that would be a bit invasive and not something to back-patch. I think what you did here is appropriate as a minimal portability fix. Maybe later somebody will look into removing the duplication, as a HEAD-only improvement. regards, tom lane