Skip to content

Commit b310ab5

Browse files
authored
Merge pull request #104 from n-riesco/patch-3
Socket::Socket: Don't throw a C++ exception
2 parents b6bc8c6 + bff4c09 commit b310ab5

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)