mirror of
https://github.com/wiiu-env/ftpiiu_plugin.git
synced 2025-01-09 10:29:22 +01:00
Restart the server on error
This commit is contained in:
parent
5da7be81b7
commit
174d13339f
@ -38,8 +38,14 @@ BOOL BackgroundThread::whileLoop() {
|
||||
this->serverSocket = -1;
|
||||
DCFlushRange(&(this->serverSocket), 4);
|
||||
}
|
||||
} else {
|
||||
this->serverSocket = create_server(PORT);
|
||||
if (this->serverSocket < 0) {
|
||||
DEBUG_FUNCTION_LINE_WARN("Creating a new ftp server failed. Trying again in 5 seconds.");
|
||||
OSSleepTicks(OSSecondsToTicks(5));
|
||||
}
|
||||
}
|
||||
mutex.unlock();
|
||||
OSSleepTicks(OSMillisecondsToTicks(16));
|
||||
OSSleepTicks(OSMillisecondsToTicks(1));
|
||||
return true;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user