Use the passed stream, not std::cerr.