Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
4c0e8172
Commit
4c0e8172
authored
Apr 08, 2019
by
Jacek Caban
Committed by
Alexandre Julliard
Apr 08, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
server: Allow creating thread kernel objects.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
80d53026
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
2 deletions
+10
-2
driver.c
dlls/ntoskrnl.exe/tests/driver.c
+0
-1
thread.c
server/thread.c
+9
-1
thread.h
server/thread.h
+1
-0
No files found.
dlls/ntoskrnl.exe/tests/driver.c
View file @
4c0e8172
...
...
@@ -822,7 +822,6 @@ static void test_ob_reference(const WCHAR *test_path)
status
=
ObReferenceObjectByHandle
(
thread_handle
,
SYNCHRONIZE
,
*
pPsThreadType
,
KernelMode
,
&
obj2
,
NULL
);
ok
(
!
status
,
"ObReferenceObjectByHandle failed: %#x
\n
"
,
status
);
todo_wine
ok
(
obj1
==
obj2
,
"obj1 != obj2
\n
"
);
ObDereferenceObject
(
obj1
);
...
...
server/thread.c
View file @
4c0e8172
...
...
@@ -133,6 +133,7 @@ static struct object_type *thread_get_type( struct object *obj );
static
int
thread_signaled
(
struct
object
*
obj
,
struct
wait_queue_entry
*
entry
);
static
unsigned
int
thread_map_access
(
struct
object
*
obj
,
unsigned
int
access
);
static
void
thread_poll_event
(
struct
fd
*
fd
,
int
event
);
static
struct
list
*
thread_get_kernel_obj_list
(
struct
object
*
obj
);
static
void
destroy_thread
(
struct
object
*
obj
);
static
const
struct
object_ops
thread_ops
=
...
...
@@ -153,7 +154,7 @@ static const struct object_ops thread_ops =
no_link_name
,
/* link_name */
NULL
,
/* unlink_name */
no_open_file
,
/* open_file */
no_kernel_obj_list
,
/* get_kernel_obj_list */
thread_get_kernel_obj_list
,
/* get_kernel_obj_list */
no_close_handle
,
/* close_handle */
destroy_thread
/* destroy */
};
...
...
@@ -209,6 +210,7 @@ static inline void init_thread_structure( struct thread *thread )
list_init
(
&
thread
->
mutex_list
);
list_init
(
&
thread
->
system_apc
);
list_init
(
&
thread
->
user_apc
);
list_init
(
&
thread
->
kernel_object
);
for
(
i
=
0
;
i
<
MAX_INFLIGHT_FDS
;
i
++
)
thread
->
inflight
[
i
].
server
=
thread
->
inflight
[
i
].
client
=
-
1
;
...
...
@@ -304,6 +306,12 @@ static void thread_poll_event( struct fd *fd, int event )
release_object
(
thread
);
}
static
struct
list
*
thread_get_kernel_obj_list
(
struct
object
*
obj
)
{
struct
thread
*
thread
=
(
struct
thread
*
)
obj
;
return
&
thread
->
kernel_object
;
}
/* cleanup everything that is no longer needed by a dead thread */
/* used by destroy_thread and kill_thread */
static
void
cleanup_thread
(
struct
thread
*
thread
)
...
...
server/thread.h
View file @
4c0e8172
...
...
@@ -89,6 +89,7 @@ struct thread
timeout_t
creation_time
;
/* Thread creation time */
timeout_t
exit_time
;
/* Thread exit time */
struct
token
*
token
;
/* security token associated with this thread */
struct
list
kernel_object
;
/* list of kernel object pointers */
};
struct
thread_snapshot
...
...
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