Re: Recent pg_regress changes break testing under SELinux

From: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: Recent pg_regress changes break testing under SELinux
Date: 2008-01-18 21:40:03
Message-ID: 20080118214003.GD11971@alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> Who decided this part of pg_regress.c was a good idea?
>
> /* try to create the test tablespace dir if it doesn't exist */
> snprintf(testtablespace, MAXPGPATH, "%s/testtablespace", abs_builddir);
> if (directory_exists(testtablespace))
> rmtree(testtablespace, true);
> make_directory(testtablespace);

Hmm, AFAICS it was applied by me in 1.26, a patch from Magnus
apparently. This was quite some time ago! I think I just passed that
part verbatim from Magnus' patch.

> The regression test Makefile is responsible for preparing that
> directory, not pg_regress. This is important because in the Postgres
> RPMs, we have to be careful to appease SELinux:

Interesting. Certainly I didn't have that in mind when I applied it.

> As far as I can see the rmtree/make_directory thrashing is useless, and
> I'm going to remove it unless a pretty good counter-argument is made.

Fine with me ...

--
Alvaro Herrera http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2008-01-18 21:44:40 Re: proposal: generic function, constructor function
Previous Message Pavel Stehule 2008-01-18 21:34:45 Re: proposal: generic function, constructor function