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
0dbe5adc
Commit
0dbe5adc
authored
Apr 02, 2015
by
Andrew Cook
Committed by
Alexandre Julliard
Apr 03, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
server: Implement job inheritance.
parent
ecd41d1d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
3 deletions
+15
-3
process.c
dlls/kernel32/tests/process.c
+0
-3
process.c
server/process.c
+15
-0
No files found.
dlls/kernel32/tests/process.c
View file @
0dbe5adc
...
...
@@ -2485,7 +2485,6 @@ static void test_jobInheritance(HANDLE job)
out
=
FALSE
;
ret
=
pIsProcessInJob
(
pi
.
hProcess
,
job
,
&
out
);
ok
(
ret
,
"IsProcessInJob error %u
\n
"
,
GetLastError
());
todo_wine
ok
(
out
,
"IsProcessInJob returned out=%u
\n
"
,
out
);
dwret
=
WaitForSingleObject
(
pi
.
hProcess
,
1000
);
...
...
@@ -2513,9 +2512,7 @@ static void test_BreakawayOk(HANDLE job)
snprintf
(
buffer
,
MAX_PATH
,
"
\"
%s
\"
tests/process.c %s"
,
selfname
,
"exit"
);
ret
=
CreateProcessA
(
NULL
,
buffer
,
NULL
,
NULL
,
FALSE
,
CREATE_BREAKAWAY_FROM_JOB
,
NULL
,
NULL
,
&
si
,
&
pi
);
todo_wine
ok
(
!
ret
,
"CreateProcessA expected failure
\n
"
);
todo_wine
expect_eq_d
(
ERROR_ACCESS_DENIED
,
GetLastError
());
if
(
ret
)
...
...
server/process.c
View file @
0dbe5adc
...
...
@@ -1039,6 +1039,14 @@ DECL_HANDLER(new_process)
return
;
}
if
(
parent
->
job
&&
(
req
->
create_flags
&
CREATE_BREAKAWAY_FROM_JOB
)
&&
!
(
parent
->
job
->
limit_flags
&
(
JOB_OBJECT_LIMIT_BREAKAWAY_OK
|
JOB_OBJECT_LIMIT_SILENT_BREAKAWAY_OK
)))
{
set_error
(
STATUS_ACCESS_DENIED
);
close
(
socket_fd
);
return
;
}
if
(
!
req
->
info_size
)
/* create an orphaned process */
{
create_process
(
socket_fd
,
NULL
,
0
);
...
...
@@ -1109,6 +1117,13 @@ DECL_HANDLER(new_process)
&&
!
(
req
->
create_flags
&
DEBUG_ONLY_THIS_PROCESS
);
process
->
startup_info
=
(
struct
startup_info
*
)
grab_object
(
info
);
if
(
parent
->
job
&&
!
(
req
->
create_flags
&
CREATE_BREAKAWAY_FROM_JOB
)
&&
!
(
parent
->
job
->
limit_flags
&
JOB_OBJECT_LIMIT_SILENT_BREAKAWAY_OK
))
{
add_job_process
(
parent
->
job
,
process
);
}
/* connect to the window station */
connect_process_winstation
(
process
,
current
);
...
...
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