Skip to content

Commit ad59b30

Browse files
committed
Socket::PollForEvents: Don't throw a C++ exception
1 parent 93d5f4e commit ad59b30

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

binding.cc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -374,8 +374,10 @@ namespace zmq {
374374
if (rc < 0) {
375375
if (zmq_errno()==EINTR) {
376376
continue;
377+
} else {
378+
Nan::ThrowError(ErrorMessage());
379+
return -1;
377380
}
378-
throw std::runtime_error(ErrorMessage());
379381
} else {
380382
break;
381383
}

0 commit comments

Comments
 (0)