- Add the linking exception text to the official ReactOS licensing text. Previously, the exception text was only available at the ReactOS website with no references from the source code.
svn path=/trunk/; revision=56479
A pointer is not a handle. A handle is not a pointer. At least in most cases. Defining STRICT in win32k revealed horrible things...
svn path=/trunk/; revision=56478
- Fix a palette leak in DIB_CreateDIBSection
- Remove PALETTE_AllocPalette and PALETTE_AllocPaletteIndexedRGB, use PALETTE_AllocPalWithHandle instead
svn path=/trunk/; revision=56476
* Implement Ctrl+C support on MessageBox. Patch by Guido Pola (prodito {at} live [dot] com).
See issue #5281 for more details.
svn path=/trunk/; revision=56475
Modify DIB_MapPaletteColors, first allocating a palette without initializing the colors, then setting up the colors. This wway we don't need to allocate an intermediate buffer.
svn path=/trunk/; revision=56474
- Implement GreCreatePaletteInternal and make NtGdiCreatePaletteInternal safe regarding user mode memory access.
- Allow allocating an indexed palette without initializing the colors
- Implement PALETTE_AllocPalWithHandle
- remove pointless Self member in PALETTE structure
- cleanup palette.h a bit
svn path=/trunk/; revision=56473
- Import isinf and isnan implementations from libwine_port and adjust port.h and config.h to support them
- Remove isinf/isnan hacks from jscript and wined3d build files
- Add missing port.h include to jscript/array.c (sent and applied upstream)
See issue #7027 for more details.
svn path=/trunk/; revision=56470
Rewrite SURFACE_AllocSurface(), which now does the part of the former SURFACE_bSetBitmapBits() as well. This is to allocate the bits for a bitmap directly with the SURFACE object in one allocation. Also don't use kernel mode sections anymore by default, but paged pool memory.
svn path=/trunk/; revision=56460
Don't calll GDIOBJ_vDereferenceObject from GDIOBJ_vUnlockObject, instead manually decrement the reference count. This allows us to ASSERT that the former function is never called with an exclusive lock held.
svn path=/trunk/; revision=56458
Never ever trust the wine file layout.
wine can load a dll when there is no file using builtins, while normal windows dont.
This fixes fusion beeing installed in the wrong places.
Loading the 2nd and 3rd copy of fusion fails atm.
svn path=/trunk/; revision=56453
Autogenerate oldnames for MSVC as well.
Currently on gcc builds we use a special def file syntax and use dlltool to create the lib, while on MSVC builds we use an asm file with aliases.
svn path=/trunk/; revision=56448
Fix a serious bug in PSEH that could lead to stack corruption and was causing CSRSS to crash, when large amounts of text were output on the console.
Background: PSEH used __builtin_alloca to allocate an SEH registration frame on the stack on demand, ie only for the first try level. But there are some nasty things with __builtin_alloca: First it DOES NOT - as one might think - free the allocated memory, once the allocation "goes out of scope", like with local variables, but only on function exit. Therefore it cannot normally be used inside a loop. The trick that PSEH used to "fix" this problem, was to save the stack pointer and reset it back at the end. This is quite problematic, since the rest of the code might assume that the stack pointer is still where it was left off after the allocation. The other thing is that __builtin_alloca() can allocate the memory whenever it likes to. It can allocate everything on function entry or not allocate anything at all, when other stack variables that went out of scope have left enough space to be reused. In csrss it now happened that the allocation was done before the stack pointer was saved, so the memory could not be freed by restoring the old stack pointer value. That lead to slowly eating up the stack since the code was inside a loop.
The allocation is now replaced with a variable sized array. The variable stays in scope until the _SEH2_END and will be automaticall cleaned up by the compiler. This also makes saving and restoring the stack pointer obsolete.
Reliability++
svn path=/trunk/; revision=56442
Remove PAGEOPs and use the argument to pass relevant information where needed,
including generally a section page table entry or a PFN_NUMBER.
In its place, the code looks for an MM_WAIT_ENTRY in the appropriate place and
waits, returning STATUS_MM_RESTART_OPERATION. Rather than copying the pagein
and CoW operations in the PAGEOP contention case, we just punt back and restart
the operation, resulting in simpler code.
svn path=/trunk/; revision=56441
When a DC has the default palette selected, use the color value from PALETTERGB() directly instead of looking it up in the dc palette (just as the code was before). Fixes skipped bitmap winetests
svn path=/trunk/; revision=56440
- In NtGdiSetPixel, return the real RGB value, which is the target format color translated back to RGB, not the desired RGB value. Fixes a few bitmap winetest.
- Handle a too large index in PALETTE_ulGetRGBColorFromIndex
svn path=/trunk/; revision=56439
- Do not null terminate buffer before initializing its length in RtlDosSearchPath_Ustr. Use unicode string functions made for this purpose instead.
See issue #7010 for more details.
svn path=/trunk/; revision=56438
- Add a small RtlException test, mainly to check that a stack overflow really throws STATUS_STACK_OVERFLOW, not STATUS_ACCESS_VIOLATION.
svn path=/trunk/; revision=56434
- add missing DBG_DECREASE_LOCK_COUNT() when deleting an object that was exclusively locked. Fixes strange hang in comctl32_winetest.
The question is: why does changing a variable, which is never checked cause such trouble?
- Don't pass the DC's clip object to IntEngCopyBits, when querying a pixel
- make acExclusiveLockCount[] 0x20 bytes long, just to be really sure, that (x & 0x1F) does never overflow it.
svn path=/trunk/; revision=56433
- Do not rely on undefined behavior to get values easily accessible as constants.
- Quick build fix. Will be sent to Wine, possibly modified.
svn path=/trunk/; revision=56432
- Implement TranslateCOLORREF, based on IntHandleSpecialColorType, but now returning both the translated color and the resulting RGB color, correctly handling DIBINDEX, which will use the given value without translation.
- Rewrite NtGdiSetPixel using IntPatBlt
- Rewrite NtGdiGetPixel using IntEngCopyBits
- Fix EXLATEOBJ_iXlateTable to return 0, when the palette index is too big, instead of wrapping around
- Remove old debugcode
svn path=/trunk/; revision=56429