Details
-
Improvement
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
None
-
None
Description
In compareBytes method of org.apache.jute.Utils class, all the individual bytes of 2 byte arrays are compared and then their lengths are compared. We can improve the performance by first having length check, since we can rule out that they aren't equal by a single if condition(O(1) operation) rather than looping through arrays(O( n ) operation).
Attachments
Issue Links
- links to