Re: Conflicting declarations for b64_encode etc. on Solaris 11.4 Beta

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Postgres bugs <pgsql-bugs(at)postgresql(dot)org>, Rainer Orth <ro(at)CeBiTec(dot)Uni-Bielefeld(dot)DE>
Subject: Re: Conflicting declarations for b64_encode etc. on Solaris 11.4 Beta
Date: 2018-02-28 23:37:27
Message-ID: 9303.1519861047@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Michael Paquier <michael(at)paquier(dot)xyz> 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

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Euler Taveira 2018-03-01 00:21:51 Re: BUG #15067: Documentation or behaviour bug with autovacuum thresholds?
Previous Message PG Bug reporting form 2018-02-28 20:57:17 BUG #15094: Errors during installation - Unescaped left brace in regex