diff --git a/src/stream_pipe.cc b/src/stream_pipe.cc index 0b0cf4eb30d59f..512c3f16e441c1 100644 --- a/src/stream_pipe.cc +++ b/src/stream_pipe.cc @@ -278,6 +278,8 @@ void StreamPipe::New(const FunctionCallbackInfo& args) { CHECK(args[1]->IsObject()); StreamBase* source = StreamBase::FromObject(args[0].As()); StreamBase* sink = StreamBase::FromObject(args[1].As()); + CHECK_NOT_NULL(source); + CHECK_NOT_NULL(sink); if (StreamPipe::New(source, sink, args.This()).IsNothing()) return; }