summaryrefslogtreecommitdiff
path: root/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'main.cpp')
-rw-r--r--main.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/main.cpp b/main.cpp
index 78f5c77..756444f 100644
--- a/main.cpp
+++ b/main.cpp
@@ -118,7 +118,7 @@ int main(int argc, char**argv) {
if (opt_stats_reset) {
runCmd(cmd_stats_reset);
}
-
+
if (opt_command) {
std::stringstream cmd;
@@ -229,6 +229,10 @@ void runCmd(const char *command) {
receiveStream.str("");
receiveStream.clear();
+ if (system("netstat -lanu | grep \":6677 \"")) {
+ return;
+ }
+
if (NULL == command) {
printError("Command is null\n");
return;