Export RtlMapSecurityErrorToNtStatus since we have it available in our RTL library (however it is still only stubbed).
[RTL][NDK]
- NT-ify a bit error.c
- Add the prototypes of the functions that manipulate the "last Win32 error" and "last NT status".
- Add the prototypes of the functions that get & set the thread-error-mode (for hard-errors).
- Define some prototypes for NTOS_MODE_USER only.
[CONSRV]
RtlGetLastNtStatus is now in the NDK, no need to keep its prototype there anymore.
svn path=/trunk/; revision=71767
Change console processes priority when the console gains or loses focus. FIXME: Win2k3 backtraces show that we should call NtUserSetInformationProcess(unimplemented in ROS) to set some win32 process foreground flags.
CORE-9911
svn path=/trunk/; revision=68716
- Correctly retrieve/set the default console properties.
- (for console.dll only): split ApplyConsoleInfo so that it only deals with displaying the confirmation dialog (and set the correct return value for the PSN_APPLY notification message); the code that really sets console properties and save them in the registry is done in the main CPL function, after the property dialog is destroyed and before the CPL returns.
svn path=/trunk/; revision=67068
- Introduce a "console configuration" library that is used by both CONSRV and the console properties applet so that they can share common code concerning getting/setting console registry properties.
- Make use of the Windows-compatible (and undocumented) CONSOLE_STATE_INFO structure for that purpose (as well as the WM_SETCONSOLEINFO): see commits r63819 and r58415 and links within for more details. Note: this structure needs to be 4-byte packed (contrary to what it is said in almost all the links from above. The difference is only visible at the level of the last member that is the ConsoleTitle string array. This was tested on windows).
- Simplify some parts of console settings initialization.
- Some work is still needed concerning how to correctly retrieve the default console settings (without touching the ConsoleTitle member of CONSOLE_STATE_INFO, contrary to what we do currently).
[CONSOLE.DLL]
- Make the console properties applet windows-compatible, in the sense that you can now run it on win2k3 and use it instead of the windows one. This implies having the same strange hacks as windows' one, namely, that the window handle parameter of the CPlApplet entry point is either used as the caller (parent) window handle, OR, as a shared section handle to shared data with CONSRV.
[KERNEL32]
- Rework the console applet initialization accordingly. Also we reload each time the console.dll when opening the console applet, and then unload it: this "allows" to reset all the global variables that console.dll may (and does) have.
svn path=/trunk/; revision=66867
- Implement NtUserResolveDesktop, which opens a desktop and a window station based on a desktop path string (format: "WinSta\Desktop").
- Move NtUserConsoleControl to a more suitable file, and implement the control code that allows CSRSS to assign console input threads to given desktops.
- Simplify a bit the code in NtUserSetInformationThread.
[CONSRV]
Turn the console input thread to a real one. There should be one such thread per desktop. When a console process is started, we open the desktop on which the process is going to start, we create a new input thread (attach it to the desktop) if needed, or reuse the existing one, and then we open the terminal on the correct desktop.
CORE-9346 #resolve #comment Fixed in revision 66662.
svn path=/trunk/; revision=66662
- Remove the USE_CONSOLE_INIT_HANDLES define since now we "support" the console initialization events.
- The events in the CONSOLE_START_INFO structure are console initialization events used for asynchronous console creation, that are set whenever console creation succeeds, or fails.
- Stubplement their usage in CONSRV.
Now we are able to fully use Windows 2k3 kernel32.dll and be able to run console programs with it.
svn path=/trunk/; revision=65449
Merge back condrv_restructure branch with everything up to revision 64079 (and up for maintenance), that made console kernel32 & winsrv CSR structures Win2k3 compliant.
CORE-7931 #comment Merged back to trunk in revision 64102.
CORE-7481 #comment kernel32 / winsrv console CSR structures are Win2k3-compliant in trunk since revision 64102 (and since revision 64079 in the condrv_restructure branch, see CORE-7931 for more details).
svn path=/trunk/; revision=64102
- some consrv/condrv code refactoring for a better code separation,
- make kernel32 / winsrv console CSR structures Win2k3-compliant (see CORE-7931); only Alloc/Attach/FreeConsole APIs are still not Win2k3-compliant.
- fixes for CsrCaptureMessageString and implementation of CsrCaptureMessageMultiUnicodeStringsInPlace .
CORE-7931 #comment Partial merge of the condrv_restructure branch in revision 63810.
svn path=/trunk/; revision=63810
Implement (undocumented) SetLastConsoleEventActive API.
Patch by Alexander Andrejevic, with a minor modification by me concerning the addition of a NotifiedLastCloseProcess member to the CONSOLE structure and a check that makes sure that only the app that asked for the notification, receives it (and so that we don't call the console control dispatcher for nothing).
This API is used by ntvdm to be sure that it gets killed when all other console apps attached to the ntvdm's console are away.
CORE-7250
svn path=/trunk/; revision=62847
Make kernel32 / winsrv console CSR structures Win2k3-compliant.
The aim is to be able to put our kernel32.dll or winsrv.dll on win2k3, and vice-versa.
Part 2/X
CORE-7931
svn path=/trunk/; revision=62833
Make kernel32 / winsrv console CSR structures Win2k3-compliant.
The aim is to be able to put our kernel32.dll or winsrv.dll on win2k3, and vice-versa.
Most of the changes consist in:
- adding a HANDLE ConsoleHandle; to the structures, representing the console handle of the current application;
- reorganizing the order of the members in the different structures;
- few structures need to hold a event handle because it appears that some APIs create a event handle to perform some sort of synchronization with the console server (this is totally unused at the moment).
- Since CsrClientCallServer returns the value of ApiMessage.Status, then just use ApiMessage.Status instead of declaring another Status variable for querying the return value of CsrClientCallServer.
Part 1/X
Aside:
The VerifyConsoleIoHandle winetest problem is solved here (see CORE-7941 for more details).
CORE-7941 #resolved #comment Fixed in revision 62460, thanks :)
CORE-7931
svn path=/trunk/; revision=62460
* Remove one time inclusions from the main header and put them back where they belong.
* Improve header inclusions.
CORE-7716
svn path=/trunk/; revision=61985
- Macros renaming.
- When switching active screen buffers, do it a bit more properly, i.e. announce it to the terminal emulator (aka. frontend) so that it will be able to change the associated console palette, be able to support displaying multi screen buffers or displaying another screen buffer than the active one (for debugging purposes or whatever), etc...
There are still some hacks and commented code, which whill be cleaned when I'll be sure that everything works and is not broken somewhere.
svn path=/trunk/; revision=60593
- Fix the second parameter WaitType (aka. NotifyAll) of CsrNotifyWait. Indeed, we used before the constants WaitAll == 0 / WaitAny == 1 (see the WAIT_TYPE enum); however, it appeared that Win2k3's CsrNotifyWait wanted a WaitType parameter == 1 when waiting for all the waits in a given wait-list. Therefore we would have to use WaitAll for waiting for any of the wait blocks, and WaitAny for waiting for all the wait blocks... looks illogical. Therefore I use instead a BOOLEAN variable (that I call NotifyAll) which is TRUE when I want to wait for all the wait blocks, and FALSE otherwise (as done e.g. for the WaitForMultipleObjects API).
- Fix its usage in CONSRV.
Magically fix key presses problems in console, when using Win2k3 csrsrv.dll ...
svn path=/trunk/; revision=60551
Now that the console server works fine, move it into its real place (as in Windows), that is, inside winsrv.dll, instead of hosting it in consrv.dll.
svn path=/trunk/; revision=59461
2013-07-13 04:54:49 +00:00
Renamed from reactos/win32ss/user/consrv/console.c (Browse further)