Browse Source

Throw if SCTP is connected after close

Paul-Louis Ageneau 4 years ago
parent
commit
31b5d6f84a
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/sctptransport.cpp

+ 1 - 1
src/sctptransport.cpp

@@ -232,7 +232,7 @@ void SctpTransport::close() {
 
 void SctpTransport::connect() {
 	if (!mSock)
-		return;
+		throw std::logic_error("Attempted SCTP connect with closed socket");
 
 	PLOG_DEBUG << "SCTP connecting";
 	changeState(State::Connecting);