aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorJohannes Schickel2010-04-05 07:22:34 +0000
committerJohannes Schickel2010-04-05 07:22:34 +0000
commitde3dd04005f802059833df1f5ac09da5c1f015c4 (patch)
tree5d3762c55af5fb28418a7150930bb24d9ce5c0b3 /engines
parent29a8cb651a09e6d42e9bf123e3866d20373dc316 (diff)
downloadscummvm-rg350-de3dd04005f802059833df1f5ac09da5c1f015c4.tar.gz
scummvm-rg350-de3dd04005f802059833df1f5ac09da5c1f015c4.tar.bz2
scummvm-rg350-de3dd04005f802059833df1f5ac09da5c1f015c4.zip
Commit of the updated version of Fingolfin's patch for bug #2981788 "TINSEL: Build with -O2 broken".
svn-id: r48534
Diffstat (limited to 'engines')
-rw-r--r--engines/tinsel/play.cpp5
-rw-r--r--engines/tinsel/sched.cpp14
2 files changed, 7 insertions, 12 deletions
diff --git a/engines/tinsel/play.cpp b/engines/tinsel/play.cpp
index 54281c9d7a..103b8f42ad 100644
--- a/engines/tinsel/play.cpp
+++ b/engines/tinsel/play.cpp
@@ -376,10 +376,9 @@ static void SoundReel(CORO_PARAM, SCNHANDLE hFilm, int column, int speed,
CORO_END_CODE;
}
-static void ResSoundReel(CORO_PARAM, const void *) {
+static void ResSoundReel(CORO_PARAM, const void *param) {
// get the stuff copied to process when it was created
- PPROCESS pProc = g_scheduler->getCurrentProcess();
- int i = *(int *)pProc->param;
+ int i = *(const int *)param;
CORO_BEGIN_CONTEXT;
CORO_END_CONTEXT(_ctx);
diff --git a/engines/tinsel/sched.cpp b/engines/tinsel/sched.cpp
index c081ff68f0..d8a44944fc 100644
--- a/engines/tinsel/sched.cpp
+++ b/engines/tinsel/sched.cpp
@@ -508,21 +508,18 @@ void Scheduler::setResourceCallback(VFPTRPP pFunc) {
/**
* The code for for restored scene processes.
*/
-static void RestoredProcessProcess(CORO_PARAM, const void *) {
+static void RestoredProcessProcess(CORO_PARAM, const void *param) {
CORO_BEGIN_CONTEXT;
INT_CONTEXT *pic;
CORO_END_CONTEXT(_ctx);
CORO_BEGIN_CODE(_ctx);
- PROCESS *pProc; // this process pointer
-
// get the stuff copied to process when it was created
- pProc = g_scheduler->getCurrentProcess();
- _ctx->pic = *((INT_CONTEXT **) pProc->param);
+ _ctx->pic = *(const PINT_CONTEXT *)param;
_ctx->pic = RestoreInterpretContext(_ctx->pic);
- AttachInterpret(_ctx->pic, pProc);
+ AttachInterpret(_ctx->pic, g_scheduler->getCurrentProcess());
CORO_INVOKE_1(Interpret, _ctx->pic);
@@ -532,9 +529,8 @@ static void RestoredProcessProcess(CORO_PARAM, const void *) {
/**
* Process Tinsel Process
*/
-static void ProcessTinselProcess(CORO_PARAM, const void *) {
- PPROCESS pProc = g_scheduler->getCurrentProcess();
- PINT_CONTEXT *pPic = (PINT_CONTEXT *) pProc->param;
+static void ProcessTinselProcess(CORO_PARAM, const void *param) {
+ const PINT_CONTEXT *pPic = (const PINT_CONTEXT *)param;
CORO_BEGIN_CONTEXT;
CORO_END_CONTEXT(_ctx);