Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
ce57e5c4
Commit
ce57e5c4
authored
Apr 26, 2018
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Apr 26, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mstask: Correctly initialize trigger count when loading a task.
Signed-off-by:
Dmitry Timoshkov
<
dmitry@baikal.ru
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
8d7d858d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
task.c
dlls/mstask/task.c
+6
-6
No files found.
dlls/mstask/task.c
View file @
ce57e5c4
...
...
@@ -968,17 +968,17 @@ static HRESULT load_job_data(TaskImpl *This, BYTE *data, DWORD size)
TRACE
(
"trigger_offset %04x, triggers end at %04x
\n
"
,
fixed
->
trigger_offset
,
(
DWORD
)(
fixed
->
trigger_offset
+
sizeof
(
USHORT
)
+
trigger_count
*
sizeof
(
TASK_TRIGGER
)));
This
->
trigger_count
=
*
(
const
USHORT
*
)
data
;
TRACE
(
"trigger_count %u
\n
"
,
trigger_count
);
task_trigger
=
(
TASK_TRIGGER
*
)(
data
+
sizeof
(
USHORT
));
if
(
This
->
trigger_count
*
sizeof
(
TASK_TRIGGER
)
>
triggers_size
)
if
(
trigger_count
*
sizeof
(
TASK_TRIGGER
)
>
triggers_size
)
{
TRACE
(
"no space for triggers data
\n
"
);
return
SCHED_E_INVALID_TASK
;
}
for
(
i
=
0
;
i
<
This
->
trigger_count
;
i
++
)
This
->
trigger_count
=
0
;
for
(
i
=
0
;
i
<
trigger_count
;
i
++
)
{
ITaskTrigger
*
trigger
;
WORD
idx
;
...
...
@@ -995,8 +995,8 @@ static HRESULT load_job_data(TaskImpl *This, BYTE *data, DWORD size)
}
}
size
-=
sizeof
(
USHORT
)
+
This
->
trigger_count
*
sizeof
(
TASK_TRIGGER
);
data
+=
sizeof
(
USHORT
)
+
This
->
trigger_count
*
sizeof
(
TASK_TRIGGER
);
size
-=
sizeof
(
USHORT
)
+
trigger_count
*
sizeof
(
TASK_TRIGGER
);
data
+=
sizeof
(
USHORT
)
+
trigger_count
*
sizeof
(
TASK_TRIGGER
);
if
(
size
<
2
*
sizeof
(
USHORT
)
+
64
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment