Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-07 Thread Ivan Gerasimov
On 08.08.2013 5:05, Alan Bateman wrote: (cc'ing net-dev). The change looks okay to me. One suggestion (while you are there) is to check the return from GetStringUTFChars so that the name returns when it fails with NULL. -Alan. On 07/08/2013 17:46, Ivan Gerasimov wrote: Hello everybody! Some

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-08 Thread Ivan Gerasimov
to cr.openjdk.java.net. -Chris. On 08/08/2013 06:01 AM, David Holmes wrote: Ivan, On 8/08/2013 2:05 PM, Ivan Gerasimov wrote: David, Alan, I added checking for NULL results and throwing OOMException if necessary. You don't need to throw it yourself: JNU_ThrowOutOfMemoryError(env, NULL); Assuming

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-08 Thread Ivan Gerasimov
a regression test isn't feasible. So, the bug will be tagged noreg-hard Michael On 08/08/13 14:39, Ivan Gerasimov wrote: Thanks, David I've updated the webrev http://cr.openjdk.java.net/~igerasim/8022584/2/webrev/. On 08.08.2013 9:01, David Holmes wrote: Ivan, On 8/08/2013 2:05 PM, Ivan Gerasimov

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-08 Thread Ivan Gerasimov
, Chris Hegarty wrote: Looks good to me. Thanks Ivan. -Chris. On 08/08/2013 02:33 PM, Ivan Gerasimov wrote: Hello Chris! Here's the update: http://cr.openjdk.java.net/~igerasim/8022584/2/webrev/ Thanks for offering the sponsorship! Here's the hg-export http://cr.openjdk.java.net/~igerasim

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-08 Thread Ivan Gerasimov
skipped on this OS - there are other tests that do this so just check if there is common terminology. (In the future we may have keyword tags to flag this as linux only etc.) Thanks, David On 9/08/2013 4:41 AM, Ivan Gerasimov wrote: Chris, if it's not too late, I'd like to include a regtest

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-08 Thread Ivan Gerasimov
Thanks, David On 9/08/2013 4:41 AM, Ivan Gerasimov wrote: Chris, if it's not too late, I'd like to include a regtest in the fix. Here's webrev that includes the test: http://cr.openjdk.java.net/~igerasim/8022584/3/webrev/ The test gets past with the fixed jdk8 and fails with jdk8-b101 and jdk7

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-08 Thread Ivan Gerasimov
Thank you Michael! On 09.08.2013 2:19, Michael McMahon wrote: Ivan, Right, it's not worth trying to do the equivalent, whatever it is, for Windows. The test is fine with me. Thanks Michael On 08/08/13 23:15, Ivan Gerasimov wrote: Michael, The test uses /proc/self/stat file to detect

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-09 Thread Ivan Gerasimov
filed 8022683 to fix GetStringUTFChars. David - On 9/08/2013 3:21 PM, David Holmes wrote: Thumbs up! Thanks, David On 9/08/2013 8:19 AM, Ivan Gerasimov wrote: Thanks David! On 09.08.2013 1:15, David Holmes wrote: Main fix looks good to me. Regression test may need some tweaking eg I think

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-12 Thread Ivan Gerasimov
conclusion. It seems reasonable to separate the issues. I agree. I'm sure when Alan suggested to check the return he didn't expect it to unravel like this :) As we know hotspot will never actually return NULL there is no urgency to add this in. On 09/08/2013 10:27, Ivan Gerasimov wrote

Re: RFR [8022584] Memory leak in some NetworkInterface methods

2013-08-12 Thread Ivan Gerasimov
Thank you Chris! On 12.08.2013 16:43, Chris Hegarty wrote: Thank you Ivan. This looks good to me. -Chris. P.S. I will give others a chance to comment. If no objections, I will push this tomorrow for you. On 12/08/2013 13:33, Ivan Gerasimov wrote: David, Chris, I reverted back NULL

RFR [8023390] Test java/net/NetworkInterface/MemLeakTest.java failed

2013-10-09 Thread Ivan Gerasimov
/ Sincerely yours, Ivan Gerasimov

Re: RFR [8023390] Test java/net/NetworkInterface/MemLeakTest.java failed

2013-10-10 Thread Ivan Gerasimov
machine, with the extra iterations? -Chris. On 09/10/2013 09:24, Ivan Gerasimov wrote: Hello all! The MemLeakTest had been added with the fix for 8022584. Since that, the test was reported to fail intermittently, even though the leak was eliminated. I couldn't ever reproduce the failure even

Re: RFR [8023390] Test java/net/NetworkInterface/MemLeakTest.java failed

2013-10-15 Thread Ivan Gerasimov
usage turns out to be unreliable. At first it seemed promising. Sincerely yours, Ivan -Chris. On 11/10/2013 20:24, Ivan Gerasimov wrote: On 10.10.2013 15:52, Ivan Gerasimov wrote: Hi Chris! I've run the test on JPRT and it took 84, 99 and 146 seconds on three different machines. When I

Re: RFR for bug JDK-8035633 TEST_BUG: java/net/NetworkInterface/Equals.java and some tests failed on windows intermittently

2014-02-27 Thread Ivan Gerasimov
Hello Eric Would you please also correct the comment on the line above your change: s/seudo/pseudo/ The typo is in all three files. Sincerely yours, Ivan On 27.02.2014 12:18, Eric Wang wrote: On 2014/2/25 16:59, Alan Bateman wrote: On 25/02/2014 08:49, Eric Wang wrote: Hi Everyone, I'm

Re: RFR: [8036088] - Thread-unsafe strtok() is used to parse

2014-03-04 Thread Ivan Gerasimov
:28, Chris Hegarty wrote: On 4 Mar 2014, at 03:25, Ivan Gerasimov ivan.gerasi...@oracle.com wrote: Yes, you're right. strtok() is thread-safe in Windows unlike its Unix counterpart. Thus using strtok_s() only adds some boundary checking in this case. Ivan, Are you now withdrawing

Re: RFR: [8036088] - Thread-unsafe strtok() is used to parse

2014-03-04 Thread Ivan Gerasimov
Thank you Chris! On 04.03.2014 16:43, Chris Hegarty wrote: On 4 Mar 2014, at 11:52, Ivan Gerasimov ivan.gerasi...@oracle.com wrote: VS compiler issues this warning on strtok() usage: : warning C4996: 'strtok': This function or variable may be unsafe. Consider using strtok_s instead

RFR [7010989]: Duplicate closure of file descriptors leads to unexpected and incorrect closure of sockets

2014-09-09 Thread Ivan Gerasimov
Hello! In the implementation of TwoStack sockets on Windows there's is a possibility of trying to close the sockets twice in the case of a failure. TwoStack implementation isn't the default one, but it still can be used with jdk7u/8u on old platforms. Would you please help review the fix?

RFR 8058824: Drop TwoStacks socket implementation in jdk9 [win] - Part I

2014-09-21 Thread Ivan Gerasimov
Hello! Here is a proposal for the first step in cleaning up the TwoStacks socket implementation. It is proposed to drom IPv6 support in the implementation of TwoStacksPlainSocketImpl class (so formally, it's no more Two Stacks). Therefore, this class will only be used when the user explicitly

Re: RFR 8058824: Drop TwoStacks socket implementation in jdk9 [win] - Part I

2014-09-23 Thread Ivan Gerasimov
Thanks Michael! On 23.09.2014 13:41, Michael McMahon wrote: Hi Ivan, Did you look at the possibility of removing the TwoStacks class altogether? For Solaris/Linux etc. ipv4 only and ipv6/v4 are all handled in the same impl class with just a switch at socket creation time, selecting AF_INET

RFR 8058965: Remove IPv6 support from TwoStacksPlainSocketImpl

2014-09-23 Thread Ivan Gerasimov
Thank you Michael! Okay. I see the part 1 in the subject line now, but maybe the bug should be updated to define the scope of the change and we should file a separate bug report then. I created the subtask to track this part (the subject of the thread is changed accordingly):

RFR 8059450: Not quite correct code sample in javadoc

2014-10-01 Thread Ivan Gerasimov
Hello! This is a javadoc bug. In the code sample a redundant argument to a constructor of URI is passed. Probably a copy-paste error. BUGURL: https://bugs.openjdk.java.net/browse/JDK-8059450 WEBREV: http://cr.openjdk.java.net/~igerasim/8059450/0/webrev/ Sincerely yours, Ivan

Re: RFR 8059450: Not quite correct code sample in javadoc

2014-10-01 Thread Ivan Gerasimov
Thanks Chris! On 01.10.2014 20:49, Chris Hegarty wrote: On 1 Oct 2014, at 01:48, Ivan Gerasimov ivan.gerasi...@oracle.com wrote: Hello! This is a javadoc bug. In the code sample a redundant argument to a constructor of URI is passed. Probably a copy-paste error. BUGURL: https

Re: RFR(M): 8060470 : Unify and simplify the implmentations of Inet{4, 6}AddressImpl_getLocalHostName()

2014-10-27 Thread Ivan Gerasimov
On 27.10.2014 21:45, Volker Simonis wrote: On Fri, Oct 24, 2014 at 7:07 PM, Ivan Gerasimov ivan.gerasi...@oracle.com wrote: Hi Volker! I'm not a Reviewer, but have a couple of minor comments. In the C source files you changed the indentation to two spaces. It looks inconsistent with other

RFR 8072466: Deadlock when starting MulticastSocket and DatagramSocket

2015-02-06 Thread Ivan Gerasimov
Hello! There has been a deadlock in jdk-net code noticed on Windows. In the bug description there's a stack snippet showing that one of the deadlocked threads stuck in the native initialization code of DualStackPlainDatagramSocketImpl and the other -- in initializing of

Re: RFR 8072466: Deadlock when starting MulticastSocket and DatagramSocket

2015-02-16 Thread Ivan Gerasimov
Can someone help review this fix please? Comments/suggestions are welcome! Sincerely yours, Ivan On 06.02.2015 20:48, Ivan Gerasimov wrote: Hello! There has been a deadlock in jdk-net code noticed on Windows. In the bug description there's a stack snippet showing that one of the deadlocked

Re: RFR 8067105: Socket returned by ServerSocket.accept() is inherited by child process on Windows

2015-01-28 Thread Ivan Gerasimov
Hi Chris! I think it's better to pass the last argument to SetHandleInformation as 0 rather than FALSE. This argument is DWORD flag, which is a bit subset of the second argument. Sincerely yours, Ivan On 28.01.2015 23:01, Chris Hegarty wrote: Reviving an old code review [1], after further

Re: RFR 8139373 : [TEST_BUG] java/net/MulticastSocket/MultiDead.java failed with timeout

2015-10-21 Thread Ivan Gerasimov
Thank you Chris for review and proofreading! :-) Sincerely yours, Ivan On 21.10.2015 15:21, Chris Hegarty wrote: Looks fine Ivan, Just a typo on: 48 Utils.adjustTimeout(CHILDREN_COUNT * CHILD_TIMEOT * 2); -Chris. On 21/10/15 11:06, Ivan Gerasimov wrote: Hello! A few failures

RFR 8139373 : [TEST_BUG] java/net/MulticastSocket/MultiDead.java failed with timeout

2015-10-21 Thread Ivan Gerasimov
Hello! A few failures of the recently added regtest were observed. The failures seem to be due to slow machines. The suggested fix is to 1) increase the timeout, 2) take into account the timeout factor from the jtreg's settings, 3) measure the time of individual cycle of the loop, and give up,

Re: RFR 8080402: File Leak in jdk/src/java.base/share/classes/sun/net/sdp/SdpSupport.java

2015-09-07 Thread Ivan Gerasimov
Hi! The close() function isn't really restartable. So, I think, it's more correct to replace RESTARTABLE(close(s), res); with res = close(s); Sincerely yours, Ivan On 07.09.2015 12:26, Vyom Tewari wrote: Hi everyone, Can you please review my changes for below bug. Bug:

Re: RFR 8072466: Deadlock when starting MulticastSocket and DatagramSocket

2015-09-05 Thread Ivan Gerasimov
://cr.openjdk.java.net/~igerasim/8072466/00/webrev/ Sincerely yours, Ivan On 17.02.2015 9:54, Ivan Gerasimov wrote: Can someone help review this fix please? Comments/suggestions are welcome! Sincerely yours, Ivan On 06.02.2015 20:48, Ivan Gerasimov wrote: Hello! There has been a deadlock in jdk

Re: RFR 8080402: File Leak in jdk/src/java.base/share/classes/sun/net/sdp/SdpSupport.java

2015-09-07 Thread Ivan Gerasimov
Thanks! It looks good to me now. Sincerely yours, Ivan On 07.09.2015 16:08, Vyom Tewari wrote: Hi All, Please find the latest diff, which contains the latest fix. http://cr.openjdk.java.net/~dfuchs/vyom/8080402/webrev.02/ Thanks, Vyom On 9/7/2015 3:48 PM, Alan Bateman wrote: On

Re: RFR 8072466: Deadlock when starting MulticastSocket and DatagramSocket

2015-09-07 Thread Ivan Gerasimov
Thank you Chris for the review! Sincerely yours, Ivan On 07.09.2015 17:39, Chris Hegarty wrote: This looks like a nice cleanup, and fix. Thanks Ivan. -Chris. On 05/09/15 15:25, Ivan Gerasimov wrote: Hi everyone! The fix didn't bring enough attention back in February for some reason. So

Re: RFR 8073542 : File Leak in jdk/src/java/base/unix/native/libnet/PlainDatagramSocketImpl.c

2015-09-16 Thread Ivan Gerasimov
Hi Vyom! The change looks fine, thanks. You've used strerr() to extract the error string, so it may be good to coordinate your patch with the fix for JDK-8133249. Robert (CCed) is working on it at the moment. Sincerely yours, Ivan On 16.09.2015 12:08, Vyom Tewari wrote: Hi All, Please

[8u-dev] Request for review and for approval to backport: 8072466: Deadlock when initializing MulticastSocket and DatagramSocket

2015-09-09 Thread Ivan Gerasimov
Hello! I'd like to backport this recent fix from jdk9 to jdk8u-dev. The fix applies *almost* cleanly after unshuffling. The only manual editing I had to do was creating Java_java_net_DualStackPlainDatagramSocketImpl_initIDs() function in DualStackPlainDatagramSocketImpl.c, which didn't exist

Re: [8u-dev] Request for Review & Approval to backport: 8073542: File Leak in jdk/src/java/base/unix/native/libnet/PlainDatagramSocketImpl.c

2016-06-06 Thread Ivan Gerasimov
Could someone please help review this simple backport? Thanks in advance, Ivan On 29.05.2016 21:08, Ivan Gerasimov wrote: As this has to be re-reviewed, sending the request to net-dev list as well. On 27.05.2016 16:46, Ivan Gerasimov wrote: Hello! I'd like to backport the fix to jdk8u

[8u-dev] Request for Review & Approval to backport: 8073542: File Leak in jdk/src/java/base/unix/native/libnet/PlainDatagramSocketImpl.c

2016-05-29 Thread Ivan Gerasimov
As this has to be re-reviewed, sending the request to net-dev list as well. On 27.05.2016 16:46, Ivan Gerasimov wrote: Hello! I'd like to backport the fix to jdk8u-dev. The fix had to be slightly adjusted due to the different way the error messages are retrieved in jdk8. Here's

Re: [PING] RFR: JDK-8135259: InetAddress.getAllByName only reports "unknown error" instead of actual cause

2016-02-10 Thread Ivan Gerasimov
Hi Ramanand! Your fix looks good to me. I'm forwarding your request to net-dev@openjdk.java.net which is probably more appropriate to review this fix. It would be good, if net-dev people can confirm they're Okay with the fix. Sincerely yours, Ivan On 10.02.2016 10:08, Ramanand Patil wrote:

RFR[10]: 8187658: Bigger buffer for GetAdaptersAddresses

2017-09-19 Thread Ivan Gerasimov
] https://msdn.microsoft.com/en-us/library/windows/desktop/aa365915(v=vs.85).aspx -- With kind regards, Ivan Gerasimov

Re: RFR[10]: 8187658: Bigger buffer for GetAdaptersAddresses

2017-09-25 Thread Ivan Gerasimov
count counting down to zero but its the same effect). Regards, Roger On 9/25/2017 1:03 PM, Ivan Gerasimov wrote: Ping. Please review the proposed change at your convenience. The fix will greatly reduce the possibility of a need to reallocate the buffer to retrieve the results (something

Re: RFR[10]: 8187658: Bigger buffer for GetAdaptersAddresses

2017-09-25 Thread Ivan Gerasimov
, will increase number of retries. With kind regards, Ivan On 9/19/17 10:50 AM, Ivan Gerasimov wrote: Hello! When retrieving information about network interfaces on Windows we make up to 2 attempts to call GetAdaptersAddresses(). It was reported that in very rare cases it may not be sufficient

[jdk10] (XXS) RFR 8189631 : Missing space in the javadoc for InetAddress.createNameService()

2017-11-14 Thread Ivan Gerasimov
} system property. + * the setting of the {@code jdk.net.hosts.file} system property. * * The default NameService is the PlatformNameService, which typically * delegates name and address resolution calls to the underlying Would you approve the fix? -- With kind regards, Ivan

Re: RFR:8194298 Add support for per Socket configuration of TCP keepalive

2018-05-12 Thread Ivan Gerasimov
penjdk.java.net/~vtewari/8194298/webrev0.4/index.html). Please find my answers in-line. Thanks, vyom On Saturday 12 May 2018 11:15 AM, Ivan Gerasimov wrote: Hi Vyom! 1) src/java.base/share/classes/sun/net/ext/ExtendedSocketOptions.java Thank you for fixing ExtendingSocketOption.options0(). I

Re: RFR:8194298 Add support for per Socket configuration of TCP keepalive

2018-05-11 Thread Ivan Gerasimov
ecate-for-removal jdk/net/Sockets.java. It’s functionality is already supported by a standard API. -- With kind regards, Ivan Gerasimov

Re: RFR:8194298 Add support for per Socket configuration of TCP keepalive

2018-05-10 Thread Ivan Gerasimov
t;too" large. -- With kind regards, Ivan Gerasimov

RFR 8203369 : Check for both EAGAIN and EWOULDBLOCK error codes

2018-05-24 Thread Ivan Gerasimov
, Ivan Gerasimov

Re: RFR 8203369 : Check for both EAGAIN and EWOULDBLOCK error codes

2018-05-24 Thread Ivan Gerasimov
vid On 25/05/2018 6:57 AM, Ivan Gerasimov wrote: Hello! On Unix systems several system calls (including pread, read, readv, recvfrom, recvmsg, send, sendfile, sendmsg, sendto) may set errno to either EAGAIN or EWOULDBLOCK on the same condition. On Linux these two constants ar

Re: RFR 8203369 : Check for both EAGAIN and EWOULDBLOCK error codes

2018-05-25 Thread Ivan Gerasimov
EWOULDBLOCK: It is descriptive enough and compiles optimally. Fortunately, we don't have to care about it now, as the fix only adds checks of errno right after calls to system functions and does not store the errno value anywhere to analyze it later. -- With kind regards, Ivan Gerasimov

Re: RFR 8203369 : Check for both EAGAIN and EWOULDBLOCK error codes

2018-05-24 Thread Ivan Gerasimov
kind regards, Ivan Cheers, David On 25/05/2018 6:57 AM, Ivan Gerasimov wrote: Hello! On Unix systems several system calls (including pread, read, readv, recvfrom, recvmsg, send, sendfile, sendmsg, sendto) may set errno to either EAGAIN or EWOULDBLOCK on the same condition. On Linux these two cons

Re: RFR 8203369 : Check for both EAGAIN and EWOULDBLOCK error codes

2018-05-24 Thread Ivan Gerasimov
Hi Wiijun! On 5/24/18 10:13 PM, Weijun Wang wrote: On May 25, 2018, at 11:58 AM, Ivan Gerasimov <ivan.gerasi...@oracle.com> wrote: I also wonder whether a smart compiler might not flag code where the errors do infact have the same value: if (errno == 11 || errno == 11) ... At lea

Re: RFR 8203369 : Check for both EAGAIN and EWOULDBLOCK error codes

2018-05-25 Thread Ivan Gerasimov
Hi David! If gcc, then we already have the same test for both constants in code with no issues. For example, java.base/unix/native/libnet/SocketInputStream.c, in NET_ReadWithTimeout(): result = NET_NonBlockingRead(fd, bufP, len); if (result == -1 && ((errno == EAGAIN) ||

Re: RFR : 8205959 : Do not restart close if errno is EINTR

2018-06-27 Thread Ivan Gerasimov
. With kind regards, Ivan -- - DML On Jun 27, 2018, at 6:15 PM, Ivan Gerasimov <mailto:ivan.gerasi...@oracle.com>> wrote: Hello! When closing a socket via NET_SocketClose(int fd), a close(fd) is called. The later is wrapped in a retry-loop, which is wrong because close() is not re

RFR : 8205959 : Do not restart close if errno is EINTR

2018-06-27 Thread Ivan Gerasimov
used descriptor from another thread to be closed. """ Would you please help review a trivial fix? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8205959 WEBREV: http://cr.openjdk.java.net/~igerasim/8205959/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR: 8205342: windows : potential memleaks in getAdapter(s) in NetworkInterface_winXP.c

2018-06-22 Thread Ivan Gerasimov
http://cr.openjdk.java.net/~mbaesken/webrevs/8205342/ <http://cr.openjdk.java.net/%7Embaesken/webrevs/8205342/> Can you fix the line lengths to make it consistent with original code? That will make it easier to look at side-by-side diffs. -Alan -- With kind regards, Ivan Gerasimov

Re: RFR: 8205342: windows : potential memleaks in getAdapter(s) in NetworkInterface_winXP.c

2018-06-25 Thread Ivan Gerasimov
calls . New webrev : http://cr.openjdk.java.net/~mbaesken/webrevs/8205342.2/ <http://cr.openjdk.java.net/%7Embaesken/webrevs/8205342.2/> Best regards, Matthias *From:*Ivan Gerasimov [mailto:ivan.gerasi...@oracle.com] *Sent:* Samstag, 23. Juni 2018 01:52 *To:* Baesken, Matthias ; n

Re: RFR 8202558 : Access to freed memory in java.base/unix/native/libnet/net_util_md.c

2018-05-02 Thread Ivan Gerasimov
I just realized that we've got a similar issue in the same file in the function initLocalIfs(). The webrev was updated in place to fix this issue as well. With kind regards, Ivan On 5/2/18 12:54 PM, Ivan Gerasimov wrote: Hello! The function needsLoopbackRoute() calls initLoopbackRoutes

RFR 8202558 : Access to freed memory in java.base/unix/native/libnet/net_util_md.c

2018-05-02 Thread Ivan Gerasimov
you please help review the fix? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8202558 WEBREV: http://cr.openjdk.java.net/~igerasim/8202558/00/webrev/ Thanks! -- With kind regards, Ivan Gerasimov

RFR [11] 8058965 : Remove IPv6 support from TwoStacksPlainSocketImpl [win]

2018-02-16 Thread Ivan Gerasimov
/~igerasim/8058965/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: [PATCH] SOCK_CLOEXEC for opening sockets

2018-07-25 Thread Ivan Gerasimov
8207335/webrev.01/ -Chris. -- With kind regards, Ivan Gerasimov

Re: RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-06 Thread Ivan Gerasimov
the changes above is available here: http://cr.openjdk.java.net/~igerasim/8198358/01/webrev/ Thanks in advance! Ivan On 3/1/18 8:43 PM, Ivan Gerasimov wrote: Hello! I'd like to do the next step toward removing the TwoStacks socket implementation on Windows. It would be aligning the two

Re: RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-09 Thread Ivan Gerasimov
will be easier to apply. That was the primary reason why I choose TwoStacks as the basis and aligned DualStack with it. It can surely be done the opposite way, though I want to make sure it is the preferable way to go. With kind regards, Ivan -Chris. On 06/03/18 20:31, Ivan Gerasimov wrote

Re: RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-06 Thread Ivan Gerasimov
regards Christoph -Original Message- From: net-dev [mailto:net-dev-boun...@openjdk.java.net] On Behalf Of Ivan Gerasimov Sent: Freitag, 2. März 2018 05:43 To: Chris Hegarty <chris.hega...@oracle.com>; net-dev@openjdk.java.net Subject: RFR [11] 8198358 : Align organi

RFR 8202091 : Rename DualStackPlainSocketImpl to PlainSocketImpl [win]

2018-04-20 Thread Ivan Gerasimov
/8194534/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR 8201510 : Merge TwoStacksPlainSocketImpl into DualStackPlainSocketImpl [win]

2018-04-19 Thread Ivan Gerasimov
Thanks again Chris! On 4/19/18 1:50 AM, Chris Hegarty wrote: On 19 Apr 2018, at 09:44, Ivan Gerasimov <ivan.gerasi...@oracle.com <mailto:ivan.gerasi...@oracle.com>> wrote: ... WEBREV:http://cr.openjdk.java.net/~igerasim/8201510/01/webrev/ <http://cr.openjdk.java.net/%7Ei

RFR 8201510 : Merge TwoStacksPlainSocketImpl into DualStackPlainSocketImpl [win]

2018-04-16 Thread Ivan Gerasimov
nks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR 8201510 : Merge TwoStacksPlainSocketImpl into DualStackPlainSocketImpl [win]

2018-04-19 Thread Ivan Gerasimov
Thanks you Chris for reviewing this! On 4/18/18 9:06 AM, Chris Hegarty wrote: Ivan, On 16/04/18 17:29, Ivan Gerasimov wrote: ... WEBREV: http://cr.openjdk.java.net/~igerasim/8201510/00/webrev/ I think this is mostly good. Just one comment. I'm not sure that this is correct. --- OLD

RFR 8202154 : Remove unused code in TwoStacksPlainDatagramSocketImpl.c

2018-04-23 Thread Ivan Gerasimov
review this cleanup? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8202154 WEBREV: http://cr.openjdk.java.net/~igerasim/8202154/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR 8202154 : Remove unused code in java.base/windows/native/libnet

2018-04-23 Thread Ivan Gerasimov
the same range, so it can be defined with constants, - NET_GetDefaultTOS() always returns zero, so it can be removed. Would you please help review this? With kind regards, Ivan On 4/23/18 2:29 PM, Ivan Gerasimov wrote: Hello! Some code in TwoStacksPlainDatagramSocketImpl.c is only relevant

Re: RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-27 Thread Ivan Gerasimov
now? Please let me know, if you'd like me to send the updated webrev set. With kind regards, Ivan On 3/27/18 6:47 AM, Chris Hegarty wrote: Ivan, On 26 Mar 2018, at 23:08, Ivan Gerasimov <ivan.gerasi...@oracle.com> wrote: Hello everyone! A few modifications were done to the patch.

Re: RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-25 Thread Ivan Gerasimov
r be closed unless we do it right here, before returning -1. I checked the other places, where family is checked to be AF_INET and can confirm there's no other places where a socket gets closed. With kind regards, Ivan -- With kind regards, Ivan Gerasimov

Re: RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-26 Thread Ivan Gerasimov
Hello everyone! A few modifications were done to the patch. Below is the list of updated parts of the patch with comments about what has changed, comparing to the previous version of the patch. The patched JDK builds fine and all the tests pass well. WEBREV-000:

Re: RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-26 Thread Ivan Gerasimov
On 3/25/18 12:11 PM, Alan Bateman wrote: On 25/03/2018 19:13, Ivan Gerasimov wrote: : In the code above, newfd was obtained from a call to accept() a few lines before this check. So, the Java code has no way of being aware of this socket, and it will never be closed unless we do it right

Re: RFR 8200181 [11] Remove superflous non-IPv4 code from Java_java_net_TwoStacksPlainSocketImpl_socketListen

2018-03-23 Thread Ivan Gerasimov
Hi Chris! On 3/23/18 11:48 AM, Chris Hegarty wrote: Ivan, On 23/03/18 18:38, Ivan Gerasimov wrote: Hi Chris! I was about to submit a patch for 8198358 that heavily modifies TwoStacksPlainSocketImpl to make it aligned with DualStackPlainSocketImpl. That patch will also remove

Re: RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-23 Thread Ivan Gerasimov
. On 06/03/18 20:31, Ivan Gerasimov wrote: In order to make is easier to review the fix, I made the webrev.ksh to generate a series of incremental webrevs from the mq patch stack. Here's the list of the incremental changes with a brief comments: WEBREV-000: http://cr.openjdk.java.net/~igerasim

Re: RFR 8200181 [11] Remove superflous non-IPv4 code from Java_java_net_TwoStacksPlainSocketImpl_socketListen

2018-03-23 Thread Ivan Gerasimov
-- With kind regards, Ivan Gerasimov

RFR [11] 8198358 : Align organization of DualStackPlainSocketImpl with TwoStacksPlainSocketImp [win]

2018-03-01 Thread Ivan Gerasimov
.) The patched JDK builds fine and all the regression tests pass Okay. Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: RFR [12] 8213490: Networking area nano cleanup

2018-11-12 Thread Ivan Gerasimov
eed analysis to understand the differences between the draft and RFC 4007 (just in case it brings up implementation or conformance test issues). -Alan -- With kind regards, Ivan Gerasimov

Re: RFR [12] 8213490: Networking area nano cleanup

2018-11-13 Thread Ivan Gerasimov
_util_md.c + * 2. If the requested port is 0 (ie. any port) then we try to bind in v4 space I still see `ie.`. Not like it really matters in this context :) With kind regards, Ivan On 11/13/18 2:29 PM, Ivan Gerasimov wrote: Thanks Pavel, looks good! *src/java.base/share/classes/sun/net/ww

Re: RFR [12] 8213490: Networking area nano cleanup

2018-11-13 Thread Ivan Gerasimov
018, at 00:35, Ivan Gerasimov wrote: Do you want to change ie. -> i.e. here as well: src/java.base/windows/native/libnet/net_util_md.c - * 2. If the reqeusted port is 0 (ie. any port) then we try to bind in v4 space + * 2. If the requested port is 0 (ie. any port) then we try to bind in v4

Re: RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly

2019-01-16 Thread Ivan Gerasimov
(not a Reviewer however). Do you think we should address the other reallocs with unhandeled return code ? Best regards, Matthias -Original Message- From: Langer, Christoph Sent: Dienstag, 15. Januar 2019 20:58 To: Ivan Gerasimov ; Baesken, Matthias ; net-dev@openjdk.java.net

Re: RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly

2019-01-15 Thread Ivan Gerasimov
Hello! Do you think it is good to go now? With kind regards, Ivan On 1/11/19 11:30 AM, Ivan Gerasimov wrote: Good catch, thank you! Indeed, if we don't reset localifsSize then we could end up accessing already freed memory, which is worse than just a memory leak. Here's the updated

RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly

2019-01-10 Thread Ivan Gerasimov
regards, Ivan Gerasimov

Re: RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly

2019-01-11 Thread Ivan Gerasimov
; 685 } Best regards, Matthias Date: Thu, 10 Jan 2019 20:29:08 -0800 From: Ivan Gerasimov To: "net-dev@openjdk.java.net" Subject: RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly Message-ID: <3dc3c26b-fea7-2538-2

Re: RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly

2019-01-11 Thread Ivan Gerasimov
return; 685 } Best regards, Matthias Date: Thu, 10 Jan 2019 20:29:08 -0800 From: Ivan Gerasimov To: "net-dev@openjdk.java.net" Subject: RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly Message-ID: <3dc3c26b-f

Re: RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly

2019-01-11 Thread Ivan Gerasimov
; 685 } Best regards, Matthias Date: Thu, 10 Jan 2019 20:29:08 -0800 From: Ivan Gerasimov To: "net-dev@openjdk.java.net" Subject: RFR 8007606 : Handle realloc() failure in unix/native/libnet/net_util_md.c correctly Message-ID: <3dc3c26b-fea7-2538-2

Re: RFR 8170494 : JNI exception pending in PlainDatagramSocketImpl.c

2019-03-21 Thread Ivan Gerasimov
eptionOccurred(env)" ) call. Java_java_net_NetworkInterface_getByInetAddress0 may return NULL if there were no interfaces found. We should not return from getMulticastInterface() in this case. With kind regards, Ivan Thanks, Vyom On Wed, Mar 20, 2019 at 9:49 PM Ivan Gerasimov mailto:iv

RFR 8170494 : JNI exception pending in PlainDatagramSocketImpl.c

2019-03-20 Thread Ivan Gerasimov
/8170494/00/webrev/ Thanks in advance! -- With kind regards, Ivan Gerasimov

Re: 8223813: (aio) Iocp.getErrorMessage should drop trailing \r\n

2019-06-12 Thread Ivan Gerasimov
if (n > 0) { NET_ThrowNew(env, err, buf); LocalFree(buf); } else { NET_ThrowNew(env, err, "FormatMessage failed"); } After all, an error *did* occur. -- With kind regards, Ivan Gerasimov

Re: 8223813: (aio) Iocp.getErrorMessage should drop trailing \r\n

2019-06-11 Thread Ivan Gerasimov
e already getLastErrorString() and getErrorString() for chars here. Also, I am not sure how to test this effectively. The code passes all tiers as-is. Thanks, Brian -- With kind regards, Ivan Gerasimov

Re: 8223813: (aio) Iocp.getErrorMessage should drop trailing \r\n

2019-06-11 Thread Ivan Gerasimov
ease see comments inline below. On Jun 11, 2019, at 5:06 PM, Ivan Gerasimov mailto:ivan.gerasi...@oracle.com>> wrote: Inet4AddressImpl.c: 1) There is an extra space after FormatMessage, Fixed. 2) It is preexisting. The code doesn't check if FormatMessage failed to allocate the buffe

Re: RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-02 Thread Ivan Gerasimov
/~igerasim/8230407/01/webrev/ With kind regards, Ivan On 10/2/19 6:44 AM, Chris Hegarty wrote: Ivan, On 01/10/2019 21:26, Ivan Gerasimov wrote: Hello! The constructors of SocketPermission and FilePermission expect a String argument with comma-separated list of actions. If the list

Re: RFR (XS) 8230415 : Avoid redundant permission checking in FilePermissionCollection and SocketPermissionCollection

2019-09-30 Thread Ivan Gerasimov
Thank you Sean for reviewing! With kind regards, Ivan On 9/27/19 7:20 AM, Sean Mullan wrote: Hi Ivan, The fix looks good. Good catch. --Sean On 8/30/19 7:32 PM, Ivan Gerasimov wrote: Hello! In the two implementations of PermissionCollection.implies(Permission), all the permissions

RFR 8233886 : TEST_BUG jdk/java/net/CookieHandler/B6791927.java hit hardcoded expiration date

2019-11-10 Thread Ivan Gerasimov
help review the fix? BUGURL: https://bugs.openjdk.java.net/browse/JDK-8233886 WEBREV: http://cr.openjdk.java.net/~igerasim/8233886/00/webrev/ -- With kind regards, Ivan Gerasimov

Re: RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-03 Thread Ivan Gerasimov
/2/19 11:40 PM, Peter Levart wrote: Hi Ivan, On 10/1/19 10:26 PM, Ivan Gerasimov wrote: Hello! The constructors of SocketPermission and FilePermission expect a String argument with comma-separated list of actions. If the list is malformed, then the constructors throw IllegalArgumentException

Re: RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-03 Thread Ivan Gerasimov
Hi Chris! On 10/3/19 8:05 AM, Chris Hegarty wrote: Ivan, On 3 Oct 2019, at 04:41, Ivan Gerasimov wrote: ... So, I filed CSR: https://bugs.openjdk.java.net/browse/JDK-8231805 to cover the addition of @throws paragraph in the javadoc of SocketPermission. I would really appreciate

Re: RFR (S) 8230407 : SocketPermission and FilePermission action list allows leading comma

2019-10-02 Thread Ivan Gerasimov
ike if we used to allow commas in arbitrary places and stopped doing that.  Instead, it just turned out that the code fails to catch one specific pattern of malformed action list. With kind regards, Ivan Cheers, -Joe On 10/2/2019 4:26 PM, Ivan Gerasimov wrote: Hi Chris! Thank you very much for

[15] RFR 8241760 : Typos: empty lines in javadoc, inconsistent indents, etc. (net and nio)

2020-03-28 Thread Ivan Gerasimov
://bugs.openjdk.java.net/browse/JDK-8241727 WEBREV: http://cr.openjdk.java.net/~igerasim/8241727/00/webrev/ Thank in advance! [1] https://bugs.openjdk.java.net/browse/JDK-8241727 -- With kind regards, Ivan Gerasimov

Re: [15] RFR 8241760 : Typos: empty lines in javadoc, inconsistent indents, etc. (net and nio)

2020-03-30 Thread Ivan Gerasimov
Thank you guy for your reviews! Pushed. On 3/30/20 5:27 AM, Daniel Fuchs wrote: Looks good to me Ivan. Thanks for this cleanup! best regards, -- daniel On 30/03/2020 03:34, Ivan Gerasimov wrote: Thank you Alan and Pavel! My apologies for a wrong link in the initial request. Here's

Re: [15] RFR 8241760 : Typos: empty lines in javadoc, inconsistent indents, etc. (net and nio)

2020-03-29 Thread Ivan Gerasimov
bly wanted to confine this change to just the formatting, but... maybe we could fix the "protocol handers" typo as an exception? Other than that, the changes look good. Thanks for doing this! -Pavel On 29 Mar 2020, at 05:44, Ivan Gerasimov wrote: Hello! The fix follows up on JDK-8241727 [1]

[14-dev] RFR : (dc) MulticastSendReceiveTests.java failing with ENOMEM when joining group (OS X 10.9)

2020-03-20 Thread Ivan Gerasimov
/browse/JDK-8044365 WEBREV: http://cr.openjdk.java.net/~igerasim/8044365/00/webrev/ Mach5 control build in progress. -- With kind regards, Ivan Gerasimov

Re: [14-dev] RFR : (dc) MulticastSendReceiveTests.java failing with ENOMEM when joining group (OS X 10.9)

2020-03-20 Thread Ivan Gerasimov
Thanks everyone for reviewing! On 3/20/20 5:39 AM, Alan Bateman wrote: On 20/03/2020 12:22, Daniel Fuchs wrote: Hi Ivan, Looks good to me. I wonder if you should add @bug 8044365 to the MulticastSendReceiveTests.java while you're at it. Every test that joins a multicast has the potential of

  1   2   >