diff options
author | 2016-11-30 11:26:58 -0800 | |
---|---|---|
committer | 2016-11-30 11:26:58 -0800 | |
commit | 3c5a868a1bbd0bf08d3c6a4213f7807f3cfdb893 (patch) | |
tree | 55e4be6969d3358562a8d2b33b5eb548b77fb0ca /test | |
parent | 523a4aa0a06de21ffe23582b373d18488f78c8e2 (diff) |
PR comments #2
Diffstat (limited to 'test')
-rw-r--r-- | test/cpp/qps/json_run_localhost.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test/cpp/qps/json_run_localhost.cc b/test/cpp/qps/json_run_localhost.cc index 409abed12e..b7b2553f12 100644 --- a/test/cpp/qps/json_run_localhost.cc +++ b/test/cpp/qps/json_run_localhost.cc @@ -61,7 +61,7 @@ std::string as_string(const T& val) { static void sighandler(int sig) { const int errno_saved = errno; - g_driver->Interrupt(); + if (g_driver != NULL) g_driver->Interrupt(); for (int i = 0; i < kNumWorkers; ++i) { if (g_workers[i]) g_workers[i]->Interrupt(); } @@ -133,6 +133,7 @@ int main(int argc, char** argv) { } delete g_driver; + g_driver = NULL; for (int i = 0; i < kNumWorkers; ++i) delete g_workers[i]; GPR_ASSERT(driver_join_status == 0); } |