Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v4]

2024-05-31 Thread Jaikiran Pai
On Fri, 31 May 2024 11:03:18 GMT, Jaikiran Pai wrote: >> Can I please get a review of this change which proposes to address the issue >> noted in https://bugs.openjdk.org/browse/JDK-8210471? >> >> `java.util.zip.Inflater` when instantiated will hold on the native resources >> which are freed o

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v4]

2024-05-31 Thread Lance Andersen
On Fri, 31 May 2024 11:03:18 GMT, Jaikiran Pai wrote: >> Can I please get a review of this change which proposes to address the issue >> noted in https://bugs.openjdk.org/browse/JDK-8210471? >> >> `java.util.zip.Inflater` when instantiated will hold on the native resources >> which are freed o

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v3]

2024-05-31 Thread Jaikiran Pai
On Fri, 31 May 2024 10:35:11 GMT, Lance Andersen wrote: > Personally, I would have had each assertThrows as its own test, as if one > fails(which should not in this case) then the rest of the assertions are > never executed until the first failure is addressed. I have now updated the PR to red

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v4]

2024-05-31 Thread Jaikiran Pai
> Can I please get a review of this change which proposes to address the issue > noted in https://bugs.openjdk.org/browse/JDK-8210471? > > `java.util.zip.Inflater` when instantiated will hold on the native resources > which are freed only when `Inflater.end()` is called. The constructor of > `j

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v3]

2024-05-31 Thread Lance Andersen
On Fri, 31 May 2024 10:09:20 GMT, Jaikiran Pai wrote: >> Can I please get a review of this change which proposes to address the issue >> noted in https://bugs.openjdk.org/browse/JDK-8210471? >> >> `java.util.zip.Inflater` when instantiated will hold on the native resources >> which are freed o

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v3]

2024-05-31 Thread Jaikiran Pai
> Can I please get a review of this change which proposes to address the issue > noted in https://bugs.openjdk.org/browse/JDK-8210471? > > `java.util.zip.Inflater` when instantiated will hold on the native resources > which are freed only when `Inflater.end()` is called. The constructor of > `j

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v2]

2024-05-30 Thread Jaikiran Pai
Now that you mentioned it was added in Java 23, I went back to check what change brought that in. Turns out it was me who introduced it, that too as recently as a few months back. I too had forgotten about it :) -Jaikiran On 31/05/24 6:40 am, Lance Andersen wrote: I was looking at jdk 22 and

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v2]

2024-05-30 Thread Lance Andersen
I was looking at jdk 22 and now see the npe was added to the constructor specification earlier this year and I reviewed it🙈 Sent from my iPad > On May 30, 2024, at 8:56 PM, Jaikiran Pai wrote: > > On Thu, 30 May 2024 14:56:00 GMT, Lance Andersen wrote: > >>> Jaikiran Pai has updated the pull

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v2]

2024-05-30 Thread Jaikiran Pai
On Thu, 30 May 2024 14:56:00 GMT, Lance Andersen wrote: >> Jaikiran Pai has updated the pull request incrementally with one additional >> commit since the last revision: >> >> introduce a basic test for GZIPInputStream > > src/java.base/share/classes/java/util/zip/GZIPInputStream.java line 97

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v2]

2024-05-30 Thread Lance Andersen
On Thu, 30 May 2024 12:32:22 GMT, Jaikiran Pai wrote: >> Can I please get a review of this change which proposes to address the issue >> noted in https://bugs.openjdk.org/browse/JDK-8210471? >> >> `java.util.zip.Inflater` when instantiated will hold on the native resources >> which are freed o

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v2]

2024-05-30 Thread Jaikiran Pai
On Thu, 30 May 2024 12:32:22 GMT, Jaikiran Pai wrote: >> Can I please get a review of this change which proposes to address the issue >> noted in https://bugs.openjdk.org/browse/JDK-8210471? >> >> `java.util.zip.Inflater` when instantiated will hold on the native resources >> which are freed o

Re: RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater [v2]

2024-05-30 Thread Jaikiran Pai
> Can I please get a review of this change which proposes to address the issue > noted in https://bugs.openjdk.org/browse/JDK-8210471? > > `java.util.zip.Inflater` when instantiated will hold on the native resources > which are freed only when `Inflater.end()` is called. The constructor of > `j

RFR: 8210471: GZIPInputStream constructor could leak an un-end()ed Inflater

2024-05-30 Thread Jaikiran Pai
Can I please get a review of this change which proposes to address the issue noted in https://bugs.openjdk.org/browse/JDK-8210471? `java.util.zip.Inflater` when instantiated will hold on the native resources which are freed only when `Inflater.end()` is called. The constructor of `java.util.zip