]> git.stg.codes - stg.git/blobdiff - projects/stargazer/plugins/other/smux/smux.cpp
Check write result and replace int with bool in return type of handlers
[stg.git] / projects / stargazer / plugins / other / smux / smux.cpp
index 8faccc2d3ed8de0fee1abd2c82beba906ae527d5..fdcaaf0207639113da6c07798c0f7c3b8e2d8ab6 100644 (file)
@@ -276,8 +276,11 @@ return NULL;
 
 void SMUX::Run()
 {
-SendOpenPDU(sock);
-SendRReqPDU(sock);
+stopped = true;
+if (!SendOpenPDU(sock))
+    return;
+if (!SendRReqPDU(sock))
+    return;
 running = true;
 stopped = false;