Commit graph

41169 commits

Author SHA1 Message Date
Sylvain Petreolle f4e17f00cb [WLANSVC]
Correctly start and report status to the service manager.


svn path=/trunk/; revision=46099
2010-03-11 16:36:11 +00:00
Kamil Hornicek 8e7d72058b [SHELL32]
- partial Wine sync, fixes crashing shlfileop winetest:
Use the current directory when copying to an empty destination. 
Fix a memory leak in SHFileOperationW.
Vincent Povirk <vincent at codeweavers dot com>

svn path=/trunk/; revision=46098
2010-03-11 14:57:05 +00:00
Kamil Hornicek e277aa50f4 fix build?
svn path=/trunk/; revision=46096
2010-03-11 11:47:13 +00:00
Kamil Hornicek fdf2da655e [KERNEL32] GetConsoleProcessList is implemented, this prevents the console winetest from crashing
svn path=/trunk/; revision=46095
2010-03-11 11:34:29 +00:00
Aleksey Bragin 3b52f6a934 [OLEAUT32]
- Sync to Wine-1.1.40.

svn path=/trunk/; revision=46093
2010-03-11 10:28:34 +00:00
James Tabor 0b49f57301 - Fix test build!
svn path=/trunk/; revision=46092
2010-03-11 03:29:01 +00:00
James Tabor e04c0cda3e - Fix build!
svn path=/trunk/; revision=46091
2010-03-11 03:28:32 +00:00
James Tabor a6789f1431 - Add new menu structures.
svn path=/trunk/; revision=46090
2010-03-11 02:43:51 +00:00
Cameron Gutman 1733eb0a2f - We forget that AE_BUFFER_OVERFLOW is normal and expected since our buffer length is 0 so don't fail if that status is returned
- For any device that actually had resources we would return STATUS_SUCCESS without building a resource list and if the device didn't have resources we would end up freeing a NULL pointer, storing stack trash in Irp->IoStatus.Information, and then returning STATUS_SUCCESS
 - Fixes reporting device resources (and possibly the VBox additions crash with ACPI enabled)

svn path=/trunk/; revision=46080
2010-03-10 22:25:40 +00:00
Christoph von Wittich 418f2cc0e1 [OLE32_WINETEST]
sync OLE32_WINETEST with wine 1.1.40

svn path=/trunk/; revision=46077
2010-03-10 21:52:40 +00:00
Christoph von Wittich f0a96d12a1 [PSDK]
add extern GUID_NULL

svn path=/trunk/; revision=46076
2010-03-10 21:52:00 +00:00
Sylvain Petreolle cd65ed5bdb [ACPI]
Fix implicit declaration warnings

svn path=/trunk/; revision=46075
2010-03-10 21:49:42 +00:00
Cameron Gutman ae6e63592d - Quit building a useless IO_RESOURCE_REQUIREMENTS_LIST (and leaking memory) in response to IRP_MN_QUERY_RESOURCES
- Actually store the IO_RESOURCE_REQUIREMENTS_LIST in Irp->IoStatus.Information in response to IRP_MN_QUERY_RESOURCE_REQUIREMENTS so the PnP manager can use it (and fixes another memory leak)

svn path=/trunk/; revision=46073
2010-03-10 21:11:23 +00:00
Daniel Reimer da63b1ca50 Sync sccbase, slbcsp, usp10, wldap32, wuapi and xinput1_3 to Wine 1.1.40
Theres more, like: comctl32, comdlg32, oleaut32, riched20, sti, version, winemp3.acm, wininet and winhttp which is above my skills or looks strange, like its not really synched (winemp3.acm!!) Feel free to play with them.

svn path=/trunk/; revision=46072
2010-03-10 20:44:19 +00:00
Sir Richard c7dbb1670a [NTOS]: List still-running processes at kernel shutdown. Useful for debugging shutdown code later.
svn path=/trunk/; revision=46069
2010-03-10 18:29:10 +00:00
Sir Richard c240396ad5 [SCM]: Fix SCM shutdown. Now all services are stopped (in my working copy with the CSRSS shutdown code).
svn path=/trunk/; revision=46068
2010-03-10 18:28:45 +00:00
Sir Richard 30cee65672 [DDK]: Add MEMORY_BARRIER missing from ioaccess.h.
svn path=/trunk/; revision=46067
2010-03-10 18:28:03 +00:00
Daniel Reimer 1511347fdc Sync mscms, msg711.acm, msgm32.acm, msimtf. msnet32, msrle32, mssip32, msvcrt20, msvfw32, msvidc32 and nddeapi to Wine 1.1.40
Even more will come.

svn path=/trunk/; revision=46063
2010-03-10 17:03:25 +00:00
Daniel Reimer 94e01c6025 Sync avifil32, hnetcfg, initpki, localspl, localui, mciavi32, mciqtz32, mciseq and mlang to Wine 1.1.40
More will come.

svn path=/trunk/; revision=46062
2010-03-10 16:21:22 +00:00
Sylvain Petreolle 5e3123f80a [WLANSVC]
- Add required libary iphlpapi

svn path=/trunk/; revision=46061
2010-03-10 16:18:32 +00:00
Daniel Reimer 9334360266 Updated README.WINE.
Additionally I added a * to all Autosyncs which lie a bit back already. Will look through them and check which are still recent.

svn path=/trunk/; revision=46058
2010-03-10 15:00:25 +00:00
Aleksey Bragin f4fa6270ae [OLE32]
- Sync to Wine-1.1.40. Along with improvements, it provides many memory corruption fixes.

svn path=/trunk/; revision=46056
2010-03-10 14:28:56 +00:00
James Tabor 5d434b2f15 - [User32] Send WM_CANCELMODE in EnableWindow.
svn path=/trunk/; revision=46054
2010-03-10 10:19:49 +00:00
Sir Richard f94bebf2d0 [KERNEL32]: Remove debug output.
svn path=/trunk/; revision=46053
2010-03-10 06:50:15 +00:00
Sir Richard 34fa6fb97b [CSRSRV]: Move the new process/thread management functions into new, dedicated files. Export some of the functions, so that win32csr can use them by linking to csrsrv. Last change needed for barebones user-mode shutdown support.
svn path=/trunk/; revision=46052
2010-03-10 06:49:53 +00:00
Sir Richard 1cd9cb22ef [CSRSS]: Split off CSRSS into a more Windows-friendly model. CSRSS.EXE is simply a stub which loads CSRSRV.DLL, where all the actual code is present.
[CSRSRV]: Mostly moved all the current CSRSS code into CSRSRV, with some very minor changes to get it workking.
[CSRSRV]: Add some more code from Alex's CSRSRV, such as thread dereferencing/deallocation, hacked to work.
[CSRSRV]: Make CsrTerminateProcess destroy each CSR thread in that process, otherwise we were always leaking a handle, so processes never died. Because of this, primary tokens would remain "in use", and when umpnpmgr attempted to do a "Create Process as User" for the second+ time, the call would fail since the token from the first process was still around. This fixed that regression from the mailing list.

svn path=/trunk/; revision=46051
2010-03-10 04:59:39 +00:00
Sir Richard fc4574d166 [NTOS]: No good deed goes unpunished. Continuing the novel/saga from a couple of days ago, it seems that now that impersonation works, various code paths are being tickled into existence. For example, it would seem parts of the system now attempt setting primary tokens. This would cause an assertion, since PspAssignPrimaryToken incorrectly dereferenced the token (leading to a double-dereference) due to an off-by-! mistake.
svn path=/trunk/; revision=46049
2010-03-10 04:12:25 +00:00
Sir Richard 90fa1d0343 [CSRSS]: Differentiate between first-try and second-try shutdown. In the first try, the console server should defer to the user/win32k server to attempt shutdown for a non-console app. However, if we end up with a second try because this did not happen, then the console server takes matters in its own hands and calls the CTRL-C handler (with some exceptions, such as system/service apps, or apps not belonging to the LUID).
svn path=/trunk/; revision=46048
2010-03-10 03:35:18 +00:00
Sir Richard cbe3e09f61 [KERNEL32]: As indicated by the comment, kernel32 should always connect to the console server, even for non-console apps (the latter will just basically ignore the request). This is needed to (at minimum) setup the Ctrl-C handler, as otherwise, only "true console" apps will have a handler, even though internally, all apps have such a handler. This is what CSRSS needs to call internally for shutting down non-GUI apps, for example. (The default CTRL-C handler will just call ExitProcess).
svn path=/trunk/; revision=46047
2010-03-10 03:32:17 +00:00
Timo Kreuzer e6baa6f072 merge r46045
svn path=/trunk/; revision=46046
2010-03-10 00:56:07 +00:00
Hervé Poussineau 4c956b83a7 Link SCSI miniport drivers only to scsiport
svn path=/trunk/; revision=46044
2010-03-09 22:36:52 +00:00
James Tabor 2d2f8b9404 - [User32] sync spy to wine 1.1.40
svn path=/trunk/; revision=46043
2010-03-09 21:14:52 +00:00
Sir Richard 4f05a88e82 [KERNEL32/CSRSS]: Register new Win32 threads with CSRSS. Add a bunch of lookup, creation, allocation, hashing and CSR thread management routines from the unused CSRSRV in trunk.
[CSRSS]: Bang in the new thread support in a bunch of places, including creating static server threads. It's very hacked and handle duplication doesn't work 100% reliably, but it gets the job done.
[CSRSS]: Add CsrGetProcessLuid, CsrImpersonateClient, CsrRevertToSelf, CsrShutdownProcesses, CsrFindProcessForShutdown required for user-mode shutdown. Right now we are able to reliably enumerate user apps (in the user LUID) and then service/system apps (in the LOCAL SYSTEM LUID).

svn path=/trunk/; revision=46042
2010-03-09 20:23:22 +00:00
Sir Richard e2d31e88e4 [KERNEL32]: Bug fix CTRL-C handler registration/deregistration/notification, needed for correct console shutdown behavior.
svn path=/trunk/; revision=46041
2010-03-09 20:13:19 +00:00
Sir Richard 9c91a4dc46 [CSRSS]: Fix yet another bug in the unused csrss code.
svn path=/trunk/; revision=46040
2010-03-09 18:22:25 +00:00
Sylvain Petreolle f316f00072 Convert battery.inf to UTF-16
Add French translation.
Add battery.inf and fdc.inf to syssetup process.

Floppy disk controllers and batteries now appear correctly in device manager.
Dedicated to aicom ;)

svn path=/trunk/; revision=46038
2010-03-09 17:21:29 +00:00
Sir Richard 6b007be4cd [NTOS]: While attempting to ressucitate the user-mode shutdown code in CSRSS (disabled since 2006), it seemed clear that one of the main steps is to obtain the caller's LUID in order to kill the right processes. This LUID is obtained from the current thread's token, and we know it's the callers since we're supposed to impersonate the caller. Unfortunately, impersonation failed, making the whole process fail.
Impersonation failed because NtImpersonateThread was actually inverting the THREAD_IMPERSONATE rights, asking the client thread for the server's permissions, and vice versa. Fixing this resulted in yet another failure.
        Analysis of this failure showed that even opening the server (ie: current) thread for THREAD_DIRECT_IMPERSONATION failed, which is unusual since the current thread should have access to all its rights. This is determined in PspCreateThread when the ETHREAD->GrantedAccess field is set.
        Continuing onto this path, tracing revealed that GrantedAccess was merely 0x1607F and not 0x1F3FF as expected, meaning that not all rights were given, including the impersonate right (0x200), explaining the failure, but not the deeper reason behind it.
        Attempting to identify which code path set this GrantedAccess, the SepAccessCheck routine came to light. A bug there caused MAXIMUM_ALLOWED accesses to fail in certain scenarios, such as when the object had no security descriptor, because MAXIMUM_ALLOWED would be granted as an absolute value, when instead of it is a flag that should grant GENERIC_ALL. Fixing that bug, the failure continued.
        Further analysis identified that the Administrators SID was being found with GENERIC_READ + WRITE + EXECUTE access, and no SID was found for GENERIC_ALL access. This happened when searching the system token's default DACL, which is assigned to the kernel (but for kernel-mode callers, this check was skipped), smss, winlogon, etc.
        The code for creating this system token was heavily hacked, so the function to create the system token, as well as NtCreateToken were refactored to use a common piece of token-creating code. Furthermode, the system token was correctly created with Local System as the user, and Administrators as one of the groups. Finally, SeDefaultDacl was used (already setup properly) instead of a badly configured Default DACL. The new shared code also correctly sets the SE_GROUP_ENABLED flag on all SE_GROUP_MANDATORY groups, and scans tokens to set the TOKEN_HAS_ADMIN_GROUP and TOKEN_HAS_TRAVERSE_PRIVILEGE flags which were not previously set.
        With the correct system token and default DACL, the Local System SID was now found, but the failure continued. This was revealed to be due to an even deeper rooted problem, as the SepIsSidInToken routine checked for SE_GROUP_ENABLED before listing a SID as "present". Although this is correct for actual groups, the User SID will never have the SE_GROUP_ENABLED flag as it is not a group. This caused any granted access ACE belonging to a user (instead of a group) to be ignored, causing either access check failures, or limited rights returned (in the MAXIMUM_ALLOWED case).
        Upon fixing this bug, the NtImpersonateThread call finally returned success, since the rights were now correct. Promptly upon calling NtOpenThreadToken to query the LUID however, the system ASSERTED with FALSE.
        The code at fault was a line in NtOpenThreadTokenEx which forcefully ASSERTed if the impersonation code path was taken, presumably because this was never tested, and ReactOS would actually always fail impersonation attempts due to the bugs fixed above. This routine was thus quickly reworked to fix some mistakes (such as forgetting to actually impersonate the client, incorrect referencing/dereferencing of thread/tokens, and assumptions about DACL creation success).
        Having fixed the NtOpenThreadTokenEx routine, the LUID query now went through for the impersonated token, but soon causing a user-mode crash, due to an incorrect parameter reference in the CsrGetProcessLuid function in the csrsrv code by Alex (which I copy/pasted to reduce code duplication).
        Fixing this final bug finally allowed the correct LUID to be queried and I was able to continue development of not-yet-commited user-mode shutdown code.

svn path=/trunk/; revision=46028
2010-03-09 10:35:58 +00:00
Sir Richard b36899aa50 [WIN32K]: Stub-plement NtUserSetInformationThread for UserInitiateShutdown and UserEndShutdown. I think we're supposed to notify Winlogon at some point, and check for races. Part of new shutdown code.
svn path=/trunk/; revision=46027
2010-03-09 09:26:46 +00:00
James Tabor d5c439798c - [User32_winetest] Restore Timer test.
svn path=/trunk/; revision=46026
2010-03-09 03:48:43 +00:00
James Tabor c03ec91188 - [User32] Fix timer crash when calling proc.
svn path=/trunk/; revision=46025
2010-03-09 03:48:05 +00:00
Sir Richard 7a43a3001f [SETUPLDR]: Fix build breakage caused by hpoussin, by linking minihal into setupldr as well.
svn path=/trunk/; revision=46023
2010-03-09 02:29:25 +00:00
Hervé Poussineau 61fef12a72 [freeldr] Load an additional SCSI driver if present (NTBOOTSYS.SYS on boot partition), to increase number of known storage devices.
Works only with very simple miniport drivers.

svn path=/trunk/; revision=46017
2010-03-08 22:04:38 +00:00
Hervé Poussineau e10fbe352c [headers] Fix type of PRTL_HEAP_PARAMETERS in ifssupp.h. Will be required soon
svn path=/trunk/; revision=46016
2010-03-08 21:42:18 +00:00
Hervé Poussineau 37d9cf31a4 Fix include directories
svn path=/trunk/; revision=46015
2010-03-08 21:40:29 +00:00
James Tabor d89923519b [User32]
- David Hedberg Fix return value for EDIT_EM_Scroll and case where EM_SCROLL with page down results in trying to scroll up past the beginning. Sync to wine 1.1.40.

svn path=/trunk/; revision=46013
2010-03-08 21:24:47 +00:00
James Tabor 8b48dd5b7c - [User32_winetest]
- Msg : Remove more tests from service. test_timers crashed on a callback which passed months ago. The rest are related to TrackMouseEvent and capture.

svn path=/trunk/; revision=46012
2010-03-08 21:20:18 +00:00
Cameron Gutman be17352b40 [CMBATT]
- Add initial cmbatt driver which mostly stubs
 - All it does right now is register a battery device with the battc driver
[BATTC]
 - Add a nearly complete battc driver (the only stuff missing is WMI)
 - Tested with our stubbed cmbatt driver but testing on Windows would be nice too
[BATTERY.INF]
 - Added battery.inf to install battery devices
[MISC]
 - Add cmbatt.sys, battc.sys, and battery.inf to bootcd
 - We still need to implement compbatt.sys
 - PS: Janderwald, you stole my commit number ;)

svn path=/trunk/; revision=46011
2010-03-08 21:09:25 +00:00
Daniel Reimer f780908ae4 Polish translation update by Maciej Bialas.
svn path=/trunk/; revision=46010
2010-03-08 21:08:20 +00:00
James Tabor 6e96e3015c - Fix a crash in user32 winetest msg.
svn path=/trunk/; revision=46009
2010-03-08 21:04:00 +00:00
James Tabor f8fced000d [User32]
- Andrew Nguyen : Ensure That WM_INITDIALOG passes the first tabstop control handle to the dialog procedure.
- Henri Verbeet : Also show dialogs right after a WM_TIMER message.

svn path=/trunk/; revision=46007
2010-03-08 20:57:24 +00:00