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
626669e1
Commit
626669e1
authored
Feb 05, 2006
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel: Use a magic ConsoleHandle value instead of create flag to pass
the CREATE_NEW_CONSOLE flag to the child.
parent
645c0cc6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
10 deletions
+7
-10
kernel_main.c
dlls/kernel/kernel_main.c
+6
-10
process.c
dlls/kernel/process.c
+1
-0
No files found.
dlls/kernel/kernel_main.c
View file @
626669e1
...
...
@@ -50,8 +50,6 @@
extern
int
__wine_set_signal_handler
(
unsigned
,
int
(
*
)(
unsigned
));
extern
int
main_create_flags
;
static
CRITICAL_SECTION
ldt_section
;
static
CRITICAL_SECTION_DEBUG
critsect_debug
=
{
...
...
@@ -142,19 +140,17 @@ static BOOL process_attach(void)
/* finish the process initialisation for console bits, if needed */
__wine_set_signal_handler
(
SIGINT
,
CONSOLE_HandleCtrlC
);
if
(
main_create_flags
&
CREATE_NEW_CONSOLE
)
if
(
NtCurrentTeb
()
->
Peb
->
ProcessParameters
->
ConsoleHandle
==
(
HANDLE
)
1
)
/* FIXME */
{
HMODULE
mod
=
GetModuleHandleA
(
0
);
if
(
RtlImageNtHeader
(
mod
)
->
OptionalHeader
.
Subsystem
==
IMAGE_SUBSYSTEM_WINDOWS_CUI
)
AllocConsole
();
}
else
if
(
!
(
main_create_flags
&
DETACHED_PROCESS
))
{
/* 1/ shall inherit console + handles
* 2/ shall create std handles, if handles are not inherited
* TBD when not using wineserver handles for console handles
*/
}
/* else TODO for DETACHED_PROCESS:
* 1/ inherit console + handles
* 2/ create std handles, if handles are not inherited
* TBD when not using wineserver handles for console handles
*/
/* Create 16-bit task */
LoadLibrary16
(
"krnl386.exe"
);
...
...
dlls/kernel/process.c
View file @
626669e1
...
...
@@ -1426,6 +1426,7 @@ static RTL_USER_PROCESS_PARAMETERS *create_user_params( LPCWSTR filename, LPCWST
}
if
(
flags
&
CREATE_NEW_PROCESS_GROUP
)
params
->
ConsoleFlags
=
1
;
if
(
flags
&
CREATE_NEW_CONSOLE
)
params
->
ConsoleHandle
=
(
HANDLE
)
1
;
/* FIXME: cf. kernel_main.c */
params
->
hStdInput
=
startup
->
hStdInput
;
params
->
hStdOutput
=
startup
->
hStdOutput
;
...
...
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