You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by GitBox <gi...@apache.org> on 2021/03/11 10:09:48 UTC

[GitHub] [commons-vfs] MaxKellermann commented on pull request #155: FileContentThreadData: lazy ArrayList initialization to save memory

MaxKellermann commented on pull request #155:
URL: https://github.com/apache/commons-vfs/pull/155#issuecomment-796623174


   @boris-petrov I did not add a `null` check to `remove()` because it should be impossible to call `remove()` without previously having called `add()` (which initializes the field).
   But if it is indeed possible (which your crash shows), then this means that `remove()` has been buggy all along: previously, the bug was just hidden because `this.inputStreamList.remove(inputStream);` did not have an effect - the given object was not there, because it was in another thread's `FileContentThreadData` instance.


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org