8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 04:43:03 +01:00

Fixed the Windows build. This solution is temporary and should be re-optimized for Beta.

This commit is contained in:
dimitr 2008-06-09 10:07:09 +00:00
parent 619746286f
commit 74c3f757f6
2 changed files with 20 additions and 13 deletions

View File

@ -119,21 +119,10 @@ public:
static void Cleanup(void*);
// Goes to low priority zone
static void enter()
{
ThreadPriorityScheduler *t = get();
fb_assert(t);
t->inside = true;
t->gonein = true;
}
static void enter();
// Goes from low priority zone
static void exit()
{
ThreadPriorityScheduler *t = get();
fb_assert(t);
t->inside = false;
}
static void exit();
// Check whether current thread has high priority
static bool boosted()
@ -163,6 +152,7 @@ public:
public:
static void enter() {}
static void exit() {}
static bool boosted()
{
return false;

View File

@ -68,6 +68,23 @@ ThreadPriorityScheduler* ThreadPriorityScheduler::get()
return TLS_GET(currentScheduler);
}
// Goes to low priority zone
void ThreadPriorityScheduler::enter()
{
ThreadPriorityScheduler *t = get();
fb_assert(t);
t->inside = true;
t->gonein = true;
}
// Goes from low priority zone
void ThreadPriorityScheduler::exit()
{
ThreadPriorityScheduler *t = get();
fb_assert(t);
t->inside = false;
}
void ThreadPriorityScheduler::init()
{
if (opMode != Running)