I've hit this when multiple tests run against the same Solr server. Some tests create a collection, do some stuff and then delete it, but there are two tests which create+delete a collection, and then assert it doesn't exist by searching it (expecting to hit an exception). While I think this isn't the best way to assert a collection doesn't exist (I intend to change this assert to use a LIST command), it did surface this concurrency bug.
The problem is that getSlicesForCollections may get a CollectionRef whose collection value may be null, therefore attempting to add null to the list. I reproduced in a test, and fixed the bug.