Skip to content

Commit bff4c09

Browse files
authored
Socket::Socket: Don't throw a C++ exception
Fixes nteract/hydrogen#515 (needs testing since I can't reproduce the issue in Hydrogen)
1 parent b6bc8c6 commit bff4c09

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

binding.cc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -552,7 +552,8 @@ namespace zmq {
552552
size_t len = sizeof(uv_os_sock_t);
553553

554554
if (zmq_getsockopt(socket_, ZMQ_FD, &socket, &len)) {
555-
throw std::runtime_error(ErrorMessage());
555+
Nan::ThrowError(ErrorMessage());
556+
return;
556557
}
557558

558559
#if ZMQ_CAN_MONITOR

0 commit comments

Comments
 (0)