On 11/29/2015 04:28 PM, Noah Misch wrote:
+BEGIN
+{
+       $windows_os = $Config{osname} eq 'MSWin32' || $Config{osname} eq 'msys';
+
+       # Determine output directories, and create them.  The base path is the
+       # TESTDIR environment variable, which is normally set by the invoking
+       # Makefile.
+       $tmp_check = $ENV{TESTDIR} ? "$ENV{TESTDIR}/tmp_check" : "tmp_check";
+       $log_path = "$tmp_check/log";
+
+       mkdir $tmp_check;
+       mkdir $log_path;
Never mutate the filesystem in a BEGIN block, because "perl -c" runs BEGIN
blocks.  (Likewise for the BEGIN block this patch adds to TestLib.)


Yeah, those two lines might belong in an INIT block. "perldoc perlmod" for details.


cheers

andrew



--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to