summaryrefslogtreecommitdiff
path: root/src/inspector_io.cc
diff options
context:
space:
mode:
authorTobias Nießen <tniessen@tnie.de>2018-05-20 17:05:25 +0200
committerMyles Borins <mylesborins@google.com>2018-05-29 14:02:29 +0200
commit5e69e1a51e7acb7f0755a58794e26ae9adf293a2 (patch)
treedc783ca6e8054b186f64509f4ce9ddf011d1a4c6 /src/inspector_io.cc
parentbfe6dc369d9a2ffd093b988a8f56b31a77571264 (diff)
downloadnode-new-5e69e1a51e7acb7f0755a58794e26ae9adf293a2.tar.gz
src: add CHECK_IMPLIES macro
This change introduces the CHECK_IMPLIES macro similar to its definition in v8 and replaces instances of CHECK with CHECK_IMPLIES where it seems appropriate. PR-URL: https://github.com/nodejs/node/pull/20914 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'src/inspector_io.cc')
-rw-r--r--src/inspector_io.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/inspector_io.cc b/src/inspector_io.cc
index ce18e98973..2934512478 100644
--- a/src/inspector_io.cc
+++ b/src/inspector_io.cc
@@ -197,7 +197,7 @@ bool InspectorIo::Start() {
}
void InspectorIo::Stop() {
- CHECK(state_ == State::kAccepting || !sessions_.empty());
+ CHECK_IMPLIES(sessions_.empty(), state_ == State::kAccepting);
Write(TransportAction::kKill, 0, StringView());
int err = uv_thread_join(&thread_);
CHECK_EQ(err, 0);