fix possible null pointer dereference in C3DStream::readArray()