Re: ssl tests aren't concurrency safe due to get_free_port() - Mailing list pgsql-hackers

From Andrew Dunstan
Subject Re: ssl tests aren't concurrency safe due to get_free_port()
Date
Msg-id 926DE9D5-FE9E-420B-9233-56F6BF26CA4C@dunslane.net
Whole thread Raw
In response to Re: ssl tests aren't concurrency safe due to get_free_port()  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
> On Nov 22, 2022, at 8:36 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
> Andres Freund <andres@anarazel.de> writes:
>> While looking into a weird buildfarm failure ([1]), I noticed this:
>
>> # Checking port 62707
>> Use of uninitialized value $pid in scalar chomp at
/mnt/resource/bf/build/grassquit/REL_11_STABLE/pgsql.build/../pgsql/src/test/perl/PostgresNode.pmline 1247. 
>> Use of uninitialized value $pid in addition (+) at
/mnt/resource/bf/build/grassquit/REL_11_STABLE/pgsql.build/../pgsql/src/test/perl/PostgresNode.pmline 1248. 
>
> Yeah, my animals are showing that too.
>
>> Not quite sure how $pid ends up uninitialized, given the code:
>>    # see if someone else has or had a reservation of this port
>>    my $pid = <$portfile>;
>>    chomp $pid;
>>    if ($pid +0 > 0)
>
> I guess the <$portfile> might return undef if the file is empty?
>

Probably, will fix in the morning

Cheers

Andrew


pgsql-hackers by date:

Previous
From: Peter Smith
Date:
Subject: Re: Logical replication missing information
Next
From: Amit Kapila
Date:
Subject: Re: [BUG] FailedAssertion in SnapBuildPurgeOlderTxn