RFR: 8312444: Delete unused parameters and variables in SocketPermission
Korov
duke at openjdk.org
Sat Mar 2 13:54:42 UTC 2024
On Sat, 2 Mar 2024 13:02:58 GMT, Andrey Turbanov <aturbanov at openjdk.org> wrote:
>> Removing unused parameter `defval` in `SocketPermission.initEphemeralPorts`, so the variable `PRIV_PORT_MAX` and `DEF_EPH_LOW` unused too.
>>
>> Removing unused parameter `cname` in `SocketPermission.authorizedIPv4` and `SocketPermission.authorizedIPv6`.
>>
>> Parameter 'action' must be not empty so `a.length > 0`, the check `a.length - 1 < 0` can be removed.
>
> Can we drop `java.net.SocketPermission#defaultDeny` field? It seems it's always has `false` value (`setDeny` is never called)
Hello @turbanoff , The code has been modified based on the review.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/18086#issuecomment-1974802160
More information about the security-dev
mailing list