- Provide a IRP_MJ_CREATE and IRP_MJ_CLOSE handler for miniport drivers so IoGetDeviceObjectPointer doesn't fail (and consequently, IoSetDeviceInterfaceState)
svn path=/trunk/; revision=47090
- Remove the hack that set DI_NEEDRESTART for all network adapters which prevented us from starting the miniport driver
- Part of the fix for bug 3716
svn path=/trunk/; revision=47089
- Return SPS_ACCEPT_NOEXCLUDE from DrvSetPointerShape because we completed the requested operation successfully
- Patch by Daniel Zimmermann
- Fixes bug 4347
svn path=/trunk/; revision=47087
- Store device settings in the "Device Parameters" key, as the kernel now does it too
- Fixes display of AC97 device in audio cpl
svn path=/trunk/; revision=47084
- co_UserDestroyWindow: ThreadInfo->pDeskInfo->hShell holds the hWnd of the Shells Desktop Window. Set it to NULL if that windows is being destroyed. Fixes bug #4902.
svn path=/trunk/; revision=47082
- IntMouseInput: Add the state of virtual keys to wParam before calling MsqInsertSystemMessage. Fixes bug #5066.
- Add and Remove MK_XBUTTON1/2 flags to CurInfo->ButtonsDown vice XBUTTON1/2.
- Code based on patches in bug #5066.
svn path=/trunk/; revision=47080
- Add Strings-Sections for several languages and add TEMP_DIR string.
Please translate the TEMP_DIR string as this is the sollution for bug #2482.
svn path=/trunk/; revision=47079
- Make cmlib, newinflib and mkhive use the Wine unicode lib instead of the host_wcsfuncs lib.
- Only the header file include/host/wcsfuncs.h is still used to map str*W functions to wcs* functions in WIN32 builds.
- Remove obsolete rtl functions.
- Make mkhive use the newinflib instead of inflib.
ATTENTION: This might break the build bot although it has been tested on Windows and Linux!!!
svn path=/trunk/; revision=47076
- Only call ExFreePool.. if Buffer is not NULL, which can occur if the Unicode String MessageNameUnsafe coming from user mode is incorrect. Fixes a bugcheck when using OllyDbg V2.0.
svn path=/trunk/; revision=47075
- Fix pointer arithmetics in the gdi batch code (&pTeb->GdiTebBatch.Buffer[0] is a PULONG, but pTeb->GdiTebBatch.Offset is a byte offset)
- To prevent this from happening again, refactor the code to use one common routine GdiAllocBatchCommand to do most of the stuff.
- Reenable gdi batch for SelectObject
- Fixes gdi handle leak, causes some drawing problems in Acrobat reader, but those are less critical and I'll investigate those.
svn path=/trunk/; revision=47074
- Revert the hack done in 47059 to apply a better solution.
- co_IntCreateWindowEx: Add the WNDS2_WMCREATEMSGPROCESSED flag to state2 member of WND after sending the WM_CREATE message.
- By setting this flag it can be examined elsewhere to determine if the window was created successfully.
- co_UserDestroyWindow: Examine above mentioned flag to make sure the windows was created before calling hook procedure to inform of destroying window.
svn path=/trunk/; revision=47073
- Change Unicode string functions from wcs* to str*W because glibc (Linux build) provides the wcs* functions but they use a wchar_t size of 32 bits instead of the required 16 bits.
- Add a str*W to wcs* wrapper (infrosrtl.c) in order to use the wcs* function for the WIN32 build.
- Add required str*W functions to the host library.
ATTENTION: This might break the build bot although it has been tested on Windows and Linux!!!
svn path=/trunk/; revision=47071
- Add an assert to PostTimerMessages to catch null pointer windows
- Add another assert to catch special windows (Window == 1)
- Improve check if the window is '1'
svn path=/trunk/; revision=47070
<bug>
- The timer implementation uses a bitmap to store window-less timers. As an optimization to find the first free index, it uses the variable "HintIndex" which points to the first timer index. In order to find the next free index, the RtlFindClearBitsAndSet function is used. When a new timer is allocated, the "HintIndex" variable is increased, which increases the search offset. Now if more than NUM_WINDOW_LESS_TIMERS (1024) timers are allocated, no more timers can be allocated because RtlFindClearBitsAndSet will claim no more index are available, because the free indexes are below the search offset.
</bug>
<fix>
Everytime a timer gets freed, store the freed index in "HintIndex". As a result the timer implementation will always find a free timer index (when there is one)
</fix>
svn path=/trunk/; revision=47069
- Store correct bus and slot information in resource lists that we give in response to IRP_MN_QUERY_RESOURCES and IRP_MN_QUERY_RESOURCE_REQUIREMENTS
- Fixes bug 4354
svn path=/trunk/; revision=47068
- Fix RtlWalkFrameChain to do usermode back traces for threads that are not system threads. Also use _SEH2_YIELD when leaving the SEH block.
svn path=/trunk/; revision=47066
- When calling NtUserCallNextHookEx check that the current hook is not the first in the chain. If so don't call the hook proc and just return, as it has already been called and it makes no sense for the NextHook function to call the first hook proc. Fixes bugs #4461 and #4407.
- The previous commit claiming to fix bug #4461 was incorrect, it may have actually fixed bug #5320. Testers please test.
svn path=/trunk/; revision=47065
- Fix a horrible casting bug
- EventCategoryData1 is a pointer to a GUID not a pointer to a UNICODE_STRING
- Convert the GUID into a UNICODE_STRING properly by using RtlStringFromGUID and pass that string to RtlCompareUnicodeString
- Fix another bug which results in us sending EventCategoryHardwareProfileChange and EventCategoryTargetDeviceChange events to everyone registered for PnP notifications
- Fixes sending EventCategoryDeviceInterfaceChange notifications that happen after calling IoRegisterPlugPlayNotification
svn path=/trunk/; revision=47064
- angle rounding for lines and polygons when SHIFT key is pressed
- equal width and height for (rounded) rectangles and ellipses when SHIFT key is pressed
Based on a patch by Katayama Hirofumi, see #5285
svn path=/trunk/; revision=47062
- Comment out the service installation for VBE and VGA so the configuration set in first-stage won't get overwritten
- Nasty graphical glitches still remain in VGA mode
- Fixes bug 2073 and bug 4192
svn path=/trunk/; revision=47061
- On backtraces, print the address of the call instruction (assumed 5 bytes lentgh) instead of the return address, which in many cases does not make sense. (WinDbg does it this way, too)
- Fix Ke386SaveFpuState to store the fpu state in the buffer, but in the pointer to the buffer
- Anable Ke386SaveFpuState to save the floating point state in KiNpxHandler and KiTrap13Handler, so we know what error we got.
- Disable saving debug registers in the trap frame, as long as the kernel doesn't support this
- Fixes ntdll_winetest exception / OllyDbg freeze/reboot
See issue #5301 for more details.
svn path=/trunk/; revision=47060
- Fix a problem where application that used WH_CBT hook procedures were receiving destroy window notification on windows that were never created. The window was never created because the application had returned a non zero value when it was notified of window creation, which effectively destroys the window and returns failure for window creation. See CBTProc Function on MSDN. Fixes bug #4461.
svn path=/trunk/; revision=47059
- Do not do callbacks to user mode while holding a lock
- Fix when WH_MOUSE_LL and WH_JOURNALRECORD are called
See issue #4926 for more details.
svn path=/trunk/; revision=47058
- Rewrite IoOpenDeviceInterfaceRegistryKey using the same helper function that is used in IoGetDeviceInterfaces and IoSetDeviceInterfaceState to reduce complexity and chance of bugs (tested and confirmed working)
- Revert r46748
- Fixes bug #5321 (AC97)
svn path=/trunk/; revision=47057
- Fix buffer size calculation for the parser.
- Do not try to execute an empty registry instruction
Patches by Roel Messiant.
- Stop the parser at the first NULL character.
Patch by me.
svn path=/trunk/; revision=47053
- Remove the useless function MachDiskNormalizeSystemPath
- Rewrite DiskGetBootPath to be much less hacky (but still not hack free)
- Freeloader doesn't have to be installed on multi(0)disk(0)rdisk(0)partition(1) (IDE primary master) anymore :)
- Freeloader successfully booted ROS after loading itself from multi(0)disk(0)rdisk(1)partition(1)
svn path=/trunk/; revision=47052
- Set the partition count to 0 for a floppy drive so it can be told apart from a cd-rom drive
- Add a last-chance sector size detection algorithm based on the partition number
- Add the same detection code to the xbox code too (it is essentially the same as what was already there just with more comments)
- Change DiskNormalizeSystemPath so it doesn't try to "normalize" a floppy boot path
- Fixes bug #5233
svn path=/trunk/; revision=47051
- Use newinflib instead of inflib.
- Pass the user-selected language to the inf parser.
- Convert registry code from ANSI APIs to UNICODE APIs.
ATTENTION: This commit might break the build bot because it was not tested on a Linux system.
svn path=/trunk/; revision=47037