aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc
diff options
context:
space:
mode:
authorGravatar Vijay Vasudevan <vrv@google.com>2017-02-17 17:05:49 -0800
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2017-02-17 17:23:48 -0800
commit93a975e114ee1c35f01ed3bdd47170e6f7129014 (patch)
treee34255aff698fe6a4a586e7940337fd278947f58 /tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc
parenteb9624017a0040e805fda622a5f9ec6681e24246 (diff)
Merge changes from github.
Change: 147897309
Diffstat (limited to 'tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc')
-rw-r--r--tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc b/tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc
index f1e435e50e..80fae4b9d8 100644
--- a/tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc
+++ b/tensorflow/core/distributed_runtime/rpc/grpc_server_lib.cc
@@ -304,7 +304,8 @@ std::unique_ptr<Master> GrpcServer::CreateMaster(MasterEnv* master_env) {
/* static */
Status GrpcServer::Create(const ServerDef& server_def, Env* env,
std::unique_ptr<ServerInterface>* out_server) {
- std::unique_ptr<GrpcServer> ret(new GrpcServer(server_def, Env::Default()));
+ std::unique_ptr<GrpcServer> ret(new GrpcServer(server_def,
+ env == nullptr ? Env::Default() : env));
TF_RETURN_IF_ERROR(ret->Init());
*out_server = std::move(ret);
return Status::OK();