aboutsummaryrefslogtreecommitdiffstats
path: root/src/platforms/posix/posixHandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/platforms/posix/posixHandler.cpp')
-rw-r--r--src/platforms/posix/posixHandler.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/platforms/posix/posixHandler.cpp b/src/platforms/posix/posixHandler.cpp
index 651b3399..91236a4f 100644
--- a/src/platforms/posix/posixHandler.cpp
+++ b/src/platforms/posix/posixHandler.cpp
@@ -33,9 +33,11 @@
#include <string.h>
+/*
#ifdef _POSIX_PRIORITY_SCHEDULING
#include <sched.h>
#endif // _POSIX_PRIORITY_SCHEDULING
+*/
namespace vmime {
@@ -205,11 +207,19 @@ vmime::utility::childProcessFactory* posixHandler::getChildProcessFactory() cons
void posixHandler::wait() const
{
+/*
#ifdef _POSIX_PRIORITY_SCHEDULING
::sched_yield();
#else
::sleep(1);
#endif // _POSIX_PRIORITY_SCHEDULING
+*/
+
+ struct timespec ts;
+ ts.tv_sec = 0;
+ ts.tv_nsec = 150000000; // 150 ms
+
+ nanosleep(&ts, NULL);
}