Thread safety problem in java.net.ProxySelector

2020-09-02 Thread David Lloyd
The default proxy selector field in java.net.ProxySelector is essentially a global variable with no thread safety measures taken to ensure that accesses are valid. Anecdotally, a symptom of this bug *may* be that the field appears `null` after assignment (based on an IRC discussion with a confused

Re: RFR(S): 8252407: Build failure with gcc-8+ and asan

2020-09-02 Thread Magnus Ihse Bursie
On 2020-09-02 09:50, Kim Barrett wrote: On Sep 2, 2020, at 2:39 AM, Magnus Ihse Bursie wrote: On 2020-09-01 11:46, Kim Barrett wrote: I really hate -Wstringop-truncation. It's been a constant source of churn for us ever since it appeared. The changes being made to getIndex and getFlags (

Re: RFR(S): 8252407: Build failure with gcc-8+ and asan

2020-09-02 Thread Daniel Fuchs
Hi, On 02/09/2020 08:19, Florian Weimer wrote: At least one of the bugs was in theory user-visible: the network interface code would return data for an interface that does not actually exist on the system. WRT NetworkInterface.c, I might support using `strnlen` to check the length before hand,

Re: RFR(S): 8252407: Build failure with gcc-8+ and asan

2020-09-02 Thread Kim Barrett
> On Sep 2, 2020, at 3:19 AM, Florian Weimer wrote: > > * Magnus Ihse Bursie: > >> Maybe we should have a common library for all native code where we >> supply our own string operation functions? It will then be much easier >> to make sure the implementation passes different compiler versions,

Re: RFR(S): 8252407: Build failure with gcc-8+ and asan

2020-09-02 Thread Kim Barrett
> On Sep 1, 2020, at 5:46 AM, Kim Barrett wrote: > >> On Sep 1, 2020, at 4:01 AM, Eric Liu wrote: >> >> Hi all, >> >> Please review this simple change to fix some compile warnings. >> >> The newer gcc (gcc-8 or higher) would warn for calls to bounded string >> manipulation functions such as '

Re: Fix for Javadoc errors in java.base

2020-09-02 Thread Vipin Sharma
Hi Sean, All 3 instances of @exception in DHPrivateKey are now replaced with @throws, added ProviderException similar to other constructor of DHPrivateKey. Updated patch: --- old/src/java.base/share/classes/com/sun/crypto/provider/DHPrivateKey.java 2020-08-14 23:55:40.921599987 +0530 +++ new

Re: RFR(S): 8252407: Build failure with gcc-8+ and asan

2020-09-02 Thread Kim Barrett
> On Sep 1, 2020, at 4:01 AM, Eric Liu wrote: > > Hi all, > > Please review this simple change to fix some compile warnings. > > The newer gcc (gcc-8 or higher) would warn for calls to bounded string > manipulation functions such as 'strncpy' that may either truncate the > copied string or leav

Re: RFR(S): 8252407: Build failure with gcc-8+ and asan

2020-09-02 Thread Kim Barrett
> On Sep 2, 2020, at 2:39 AM, Magnus Ihse Bursie > wrote: > > On 2020-09-01 11:46, Kim Barrett wrote: >> I really hate -Wstringop-truncation. It's been a constant source of churn >> for us ever since it appeared. The changes being made to getIndex and >> getFlags (NetworkInterface.c) are modif

Re: RFR(S): 8252407: Build failure with gcc-8+ and asan

2020-09-02 Thread Florian Weimer
* Magnus Ihse Bursie: > Maybe we should have a common library for all native code where we > supply our own string operation functions? It will then be much easier > to make sure the implementation passes different compiler versions, > and that we provide sane semantics (which isn't really theĀ  c