summaryrefslogtreecommitdiff
path: root/src/node_messaging.cc
diff options
context:
space:
mode:
authorZYSzys <17367077526@163.com>2019-02-04 15:38:51 +0800
committerDaniel Bevenius <daniel.bevenius@gmail.com>2019-02-07 07:22:38 +0100
commit93e0c6ae8997e0ded6013078efd0ccc652ca2595 (patch)
tree335126a828eb71730196f0df21998a3eaf0f5328 /src/node_messaging.cc
parent2a212549dc0517f1700db90d66ed5cf09e9513b8 (diff)
downloadandroid-node-v8-93e0c6ae8997e0ded6013078efd0ccc652ca2595.tar.gz
android-node-v8-93e0c6ae8997e0ded6013078efd0ccc652ca2595.tar.bz2
android-node-v8-93e0c6ae8997e0ded6013078efd0ccc652ca2595.zip
src: use NULL check macros to check nullptr
PR-URL: https://github.com/nodejs/node/pull/25916 Refs: https://github.com/nodejs/node/pull/20914 Reviewed-By: Masashi Hirano <shisama07@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Diffstat (limited to 'src/node_messaging.cc')
-rw-r--r--src/node_messaging.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/node_messaging.cc b/src/node_messaging.cc
index 9952043f7b..896f43cd23 100644
--- a/src/node_messaging.cc
+++ b/src/node_messaging.cc
@@ -376,7 +376,7 @@ void Message::MemoryInfo(MemoryTracker* tracker) const {
MessagePortData::MessagePortData(MessagePort* owner) : owner_(owner) { }
MessagePortData::~MessagePortData() {
- CHECK_EQ(owner_, nullptr);
+ CHECK_NULL(owner_);
Disentangle();
}
@@ -402,8 +402,8 @@ bool MessagePortData::IsSiblingClosed() const {
}
void MessagePortData::Entangle(MessagePortData* a, MessagePortData* b) {
- CHECK_EQ(a->sibling_, nullptr);
- CHECK_EQ(b->sibling_, nullptr);
+ CHECK_NULL(a->sibling_);
+ CHECK_NULL(b->sibling_);
a->sibling_ = b;
b->sibling_ = a;
a->sibling_mutex_ = b->sibling_mutex_;