Thread: pgcrypto: make const array static

pgcrypto: make const array static

From
Neil Conway
Date:
This one-line patches merges a micro-opt from upstream (OpenBSD)
sources: we can make a read-only local array "static" and reduce the
size of the generated object file slightly.

Barring any objections, I intend to apply this patch today or tomorrow.

-Neil
Index: contrib/pgcrypto/blf.c
===================================================================
RCS file: /Users/neilc/local/cvs/pgsql-server/contrib/pgcrypto/blf.c,v
retrieving revision 1.5
diff -c -r1.5 blf.c
*** contrib/pgcrypto/blf.c    29 Jan 2002 15:40:45 -0000    1.5
--- contrib/pgcrypto/blf.c    3 Oct 2004 16:07:31 -0000
***************
*** 126,132 ****

  /* P-box and S-box tables initialized with digits of Pi */

!     const blf_ctx initstate =

      {{
              {
--- 126,132 ----

  /* P-box and S-box tables initialized with digits of Pi */

!     static const blf_ctx initstate =

      {{
              {

Re: pgcrypto: make const array static

From
Neil Conway
Date:
On Mon, 2004-10-04 at 15:23, Neil Conway wrote:
> This one-line patches merges a micro-opt from upstream (OpenBSD)
> sources: we can make a read-only local array "static" and reduce the
> size of the generated object file slightly.

Patch applied.

-Neil