Skip to content

Commit

Permalink
fix protobuf client ParseFromArray error
Browse files Browse the repository at this point in the history
  • Loading branch information
baotiao committed Sep 25, 2017
1 parent 8f1e0fc commit e740615
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pink/src/pb_cli.cc
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,9 @@ Status PbCli::Recv(void *msg_res) {
return s;
}

res->ParseFromArray(rbuf_, packet_len);
if (!res->ParseFromArray(rbuf_ , packet_len)) {
return Status::Corruption("PbCli::Recv Protobuf ParseFromArray error");
}
return Status::OK();
}

Expand Down

0 comments on commit e740615

Please sign in to comment.