pgsql: Move a couple of initdb's subroutines into src/port/. - Mailing list pgsql-committers

From Tom Lane
Subject pgsql: Move a couple of initdb's subroutines into src/port/.
Date
Msg-id E1PRDYT-0003wK-1f@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Move a couple of initdb's subroutines into src/port/.

mkdir_p and check_data_dir will be useful in CREATE TABLESPACE, since we
have agreed that that command should handle subdirectory creation just like
initdb creates the PGDATA directory.  Push them into src/port/ so that they
are available to both initdb and the backend.  Rename to pg_mkdir_p and
pg_check_dir, just to be on the safe side.  Add FreeBSD's copyright notice
to pgmkdirp.c, since that's where the code came from originally (this
really should have been in initdb.c).  Very marginal code/comment cleanup.

Branch
------
master

Details
-------
http://git.postgresql.org/gitweb?p=postgresql.git;a=commitdiff;h=671199929d09397e0a60e269aec28846669216db

Modified Files
--------------
src/bin/initdb/initdb.c |  172 ++---------------------------------------------
src/include/port.h      |    6 ++
src/port/Makefile       |   10 ++-
src/port/pgcheckdir.c   |   73 ++++++++++++++++++++
src/port/pgmkdirp.c     |  148 ++++++++++++++++++++++++++++++++++++++++
5 files changed, 240 insertions(+), 169 deletions(-)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Use symbolic names not octal constants for file permission flags
Next
From: Robert Haas
Date:
Subject: pgsql: Minor documentation cleanup.