]> git.tdb.fi Git - libs/core.git/commitdiff
Change sched_yield to a short sleep to improve performance on slower machines
authorMikko Rasa <tdb@tdb.fi>
Wed, 6 Sep 2006 20:53:38 +0000 (20:53 +0000)
committerMikko Rasa <tdb@tdb.fi>
Wed, 6 Sep 2006 20:53:38 +0000 (20:53 +0000)
source/core/application.cpp

index a9aa88ea55bdee578d81238d614120a962be2173..01bb558e279255fbb5f83676c61886966f9624b2 100644 (file)
@@ -124,7 +124,9 @@ int Application::main()
 #ifdef WIN32
                        Sleep(0);
 #else
-                       sched_yield();
+                       //sched_yield();
+                       timespec ts={0,1000000};
+                       nanosleep(&ts, 0);
 #endif
                }
                else