Replace CHECK() by a warning in MapBuilderStub::SerializeState() (#1364)

See discussion in https://github.com/googlecartographer/cartographer_ros/pull/966
master
Michael Grupp 2018-08-02 19:35:19 +02:00 committed by Wally B. Feed
parent 39e5943abc
commit 4cd1528ffb
1 changed files with 4 additions and 2 deletions

View File

@ -125,8 +125,10 @@ std::string MapBuilderStub::SubmapToProto(
void MapBuilderStub::SerializeState(bool include_unfinished_submaps,
io::ProtoStreamWriterInterface* writer) {
CHECK(!include_unfinished_submaps)
<< "Writing of unfinished submaps is unsupported.";
if (!include_unfinished_submaps) {
LOG(WARNING) << "Serializing unfinished submaps is currently unsupported. "
"Proceeding to write the state without them.";
}
google::protobuf::Empty request;
async_grpc::Client<handlers::WriteStateSignature> client(client_channel_);
CHECK(client.Write(request));