From 472a729cc84f7631f404d0e7d51a77586646367c Mon Sep 17 00:00:00 2001 From: terax111 <42743785+terax111@users.noreply.github.com> Date: Tue, 26 Oct 2021 23:55:07 +0200 Subject: [PATCH] Added returns to catch block of OpenPort and OpenVirtualPort --- src/input.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/input.cpp b/src/input.cpp index de9b168..2d9bb97 100644 --- a/src/input.cpp +++ b/src/input.cpp @@ -171,7 +171,7 @@ NAN_METHOD(NodeMidiInput::OpenPort) input->in->openPort(portNumber); } catch(RtMidiError& e) { - ; + return Nan::ThrowError("Error while opening port"); } return; } @@ -197,7 +197,7 @@ NAN_METHOD(NodeMidiInput::OpenVirtualPort) input->in->openVirtualPort(name); } catch(RtMidiError& e) { - ; + return Nan::ThrowError("Error while opening virtual port"); } return; }