mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-29 20:27:49 +02:00
daemonization.
This commit is contained in:
parent
3a864cb6c5
commit
334c92bb49
6 changed files with 74 additions and 46 deletions
10
i2p.cpp
10
i2p.cpp
|
@ -5,11 +5,13 @@
|
|||
int main( int argc, char* argv[] )
|
||||
{
|
||||
Daemon.init(argc, argv);
|
||||
Daemon.start();
|
||||
while (Daemon.running)
|
||||
if (Daemon.start())
|
||||
{
|
||||
//TODO Meeh: Find something better to do here.
|
||||
std::this_thread::sleep_for (std::chrono::seconds(1));
|
||||
while (Daemon.running)
|
||||
{
|
||||
//TODO Meeh: Find something better to do here.
|
||||
std::this_thread::sleep_for (std::chrono::seconds(1));
|
||||
}
|
||||
}
|
||||
Daemon.stop();
|
||||
return EXIT_SUCCESS;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue