packageurl-java icon indicating copy to clipboard operation
packageurl-java copied to clipboard

fix: Fix some issues with `StringUtilBenchmark`

Open dwalluck opened this issue 10 months ago • 0 comments

  • Make Random static even though in practice it should only be created once already (fixes SpotBugs warning)
  • Initialize fields to empty to prevent warning "@NullMarked fields must be initialized"
  • Iterate over decodedData directly instead of using the DATA_COUNT constant even though in practice these should always have the same length
  • Fill data fields directly instead of using a local variables/parameters with the same names

dwalluck avatar Apr 02 '25 15:04 dwalluck