src/thread_none.cpp
author miham
Tue, 15 Jul 2008 23:27:28 +0000
changeset 11149 f3ff534dded8
parent 10866 242436c016b8
permissions -rw-r--r--
(svn r13707) -Update: WebTranslator2 update to 2008-07-16 01:21:36
brazilian_portuguese - 3 fixed by tucalipe (3)
bulgarian - 78 fixed, 230 changed by thetitan (3), groupsky (305)
catalan - 3 fixed by arnaullv (3)
dutch - 3 fixed by webfreakz (3)
italian - 3 changed by lorenzodv (3)
korean - 4 fixed, 5 changed by leejaeuk5 (9)
russian - 3 fixed by Smoky555 (3)
slovenian - 4 fixed by Necrolyte (4)
spanish - 3 fixed by eusebio (3)
swedish - 4 fixed by daishan (4)
ukrainian - 2 fixed by mad (2)
10175
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
     1
/* $Id$ */
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
     2
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
     3
/** @file thread_none.cpp No-Threads-Available implementation of Threads */
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
     4
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
     5
#include "stdafx.h"
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
     6
#include "thread.h"
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
     7
#include "fiber.hpp"
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
     8
10866
242436c016b8 (svn r13417) -Fix (r12945, r13413): freeing the ThreadObjects in a manner that hopefully doesn't cause crashes.
rubidium
parents: 10861
diff changeset
     9
/* static */ ThreadObject *ThreadObject::New(OTTDThreadFunc proc, void *param)
10175
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    10
{
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    11
	return NULL;
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    12
}
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    13
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    14
/* static */ ThreadObject *ThreadObject::AttachCurrent()
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    15
{
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    16
	return NULL;
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    17
}
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    18
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    19
/* static */ uint ThreadObject::CurrentId()
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    20
{
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    21
	return -1;
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    22
}
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    23
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    24
/* static */ ThreadSemaphore *ThreadSemaphore::New()
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    25
{
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    26
	return NULL;
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    27
}
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    28
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    29
/* static */ Fiber *Fiber::New(FiberFunc proc, void *param)
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    30
{
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    31
	return NULL;
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    32
}
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    33
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    34
/* static */ Fiber *Fiber::AttachCurrent(void *param)
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    35
{
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    36
	return NULL;
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    37
}
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    38
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    39
/* static */ void *Fiber::GetCurrentFiberData()
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    40
{
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    41
	return NULL;
1119f6640ee6 (svn r12706) -Merge: the thread rewrite from NoAI. The rewrite makes the threading we have better extendable.
rubidium
parents:
diff changeset
    42
}