timgrein opened a new pull request, #16296:
URL: https://github.com/apache/lucene/pull/16296

   When [checking an 
array](https://github.com/apache/lucene/blob/f3d493be97174bba4dcafc0bde23565091b8da04/lucene/core/src/java/org/apache/lucene/util/RamUsageEstimator.java#L593-L597)
 of `Accountable` there's an explicit `null` check avoiding NPEs, which would 
happen, when calling `accountable.ramBytesUsed()`.
   
   For the [single object 
version](https://github.com/apache/lucene/blob/f3d493be97174bba4dcafc0bde23565091b8da04/lucene/core/src/java/org/apache/lucene/util/RamUsageEstimator.java#L429-L432)
 `sizeOf(Accountable accountable)` this is not the case, therefore aligning the 
implementations.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to