reactos.git
6 years ago[DISK]: Small fixes:
Hermès Bélusca-Maïto [Mon, 8 May 2017 21:34:07 +0000 (21:34 +0000)]
[DISK]: Small fixes:
- Check for malformed disk identifier, which must be at least 9 WCHARs long (as done by disk_new);
- Prevent possible memory leaks (missing ExFreePool's) + closing registry key.
Investigated by Lesan Ilie during tests; as part of CORE-13131.
- Make one of our hacks more readable (by me).
(We also note that this driver uses the ExAllocate/FreePool functions in the old-school way).

svn path=/trunk/; revision=74509

6 years agoMore build fixes.
Giannis Adamopoulos [Mon, 8 May 2017 19:08:30 +0000 (19:08 +0000)]
More build fixes.

svn path=/trunk/; revision=74508

6 years agoFix build.
Giannis Adamopoulos [Mon, 8 May 2017 19:02:49 +0000 (19:02 +0000)]
Fix build.

svn path=/trunk/; revision=74507

6 years ago[DESK.CPL] -Implement opening msstyles files.
Giannis Adamopoulos [Mon, 8 May 2017 18:45:35 +0000 (18:45 +0000)]
[DESK.CPL] -Implement opening msstyles files.

svn path=/trunk/; revision=74506

6 years ago[EXPLORER] Some style suggestions by Mark Jansen. Thanks
Robert Naumann [Mon, 8 May 2017 17:46:55 +0000 (17:46 +0000)]
[EXPLORER] Some style suggestions by Mark Jansen. Thanks

svn path=/trunk/; revision=74505

6 years ago[CONSOLE.CPL]: Fix the console window preview:
Hermès Bélusca-Maïto [Mon, 8 May 2017 17:33:33 +0000 (17:33 +0000)]
[CONSOLE.CPL]: Fix the console window preview:
- turn it into a custom control;
- supports dynamic preview area depending on the actual current monitor screen resolution;
  (note that on ReactOS, the WM_DISPLAYCHANGE is not correctly sent, see CORE-13212, therefore this functionality won't show up yet)
- supports correct rescaling of the console preview drawn in the preview area;
- supports dependence of the console preview with respect to the chosen font character dimensions.
The code is there, it may be a little bit improved in the future.
CORE-13196 #resolve

Other additions:
- Add a few space between the console preview text window border and the text sample;
- PaintText and PaintStaticControls do not need to return anything.

svn path=/trunk/; revision=74504

6 years ago[CONSOLE.CPL]: Minor modifications:
Hermès Bélusca-Maïto [Mon, 8 May 2017 17:24:57 +0000 (17:24 +0000)]
[CONSOLE.CPL]: Minor modifications:
- Use "hDlg" (as done in the rest of the code) instead of "hwndDlg";
- Refresh the console window preview whenever a dimension or a position was changed.

svn path=/trunk/; revision=74503

6 years ago[CONSOLE.CPL]: Simplify the color selection code by factorizing common parts.
Hermès Bélusca-Maïto [Mon, 8 May 2017 17:19:07 +0000 (17:19 +0000)]
[CONSOLE.CPL]: Simplify the color selection code by factorizing common parts.

svn path=/trunk/; revision=74502

6 years ago[EXPLORER] Addendum to r74500. Those 2 commits belong to CORE-11498
Robert Naumann [Mon, 8 May 2017 15:50:07 +0000 (15:50 +0000)]
[EXPLORER] Addendum to r74500. Those 2 commits belong to CORE-11498

svn path=/trunk/; revision=74501

6 years ago[EXPLORER]
Robert Naumann [Mon, 8 May 2017 15:27:33 +0000 (15:27 +0000)]
[EXPLORER]
- Load and save "Lock Taskbar", "Hide inactive icons", and "Group similar taskbar buttons". Verified on Win2k3 via "Nirsoft RegFromApp".
- use a loader function for registry values.
- save the "show seconds" setting together with the other explorer settings instead of a ROS specific key.
- Add some documentation comments.

svn path=/trunk/; revision=74500

6 years ago[WIN32SS] Fix font names not including style info (Bold etc). Patch by Katayama Hirof...
Mark Jansen [Mon, 8 May 2017 14:53:30 +0000 (14:53 +0000)]
[WIN32SS] Fix font names not including style info (Bold etc). Patch by Katayama Hirofumi MZ. CORE-12179 #comment Thanks!

svn path=/trunk/; revision=74499

6 years ago[SHELL32]
Thomas Faber [Mon, 8 May 2017 10:59:27 +0000 (10:59 +0000)]
[SHELL32]
- Avoid leaking the list items on destruction of CEnumIDListBase
CORE-13194

svn path=/trunk/; revision=74498

6 years ago[USER32]
Thomas Faber [Mon, 8 May 2017 08:29:17 +0000 (08:29 +0000)]
[USER32]
- Avoid a memory leak in User32EnumWindows in case the window count is zero.
CORE-13194

svn path=/trunk/; revision=74497

6 years ago[NTOS:IO]
Thomas Faber [Mon, 8 May 2017 06:54:35 +0000 (06:54 +0000)]
[NTOS:IO]
- Use pool tagging

svn path=/trunk/; revision=74496

6 years ago[NTOS]: Addendums to r74491 and r74493:
Hermès Bélusca-Maïto [Mon, 8 May 2017 00:58:45 +0000 (00:58 +0000)]
[NTOS]: Addendums to r74491 and r74493:
- Free the FullServiceName buffer if PnpRootCreateDevice failed (erroneously committed in r74494, see pnpmgr.c line 1080);
- No need to close InstanceHandle if the IopCreateDeviceKeyPath call failed, since in this case the registry handle wasn't opened. CORE-13207
- Don't assert on Buffer allocation but return a proper failure code in case of failure. CORE-13208
These are suggestions from Serge Gautherie + Lesan Ilie.

- Add a forgotten ZwClose call in the success code path of IopCreateDeviceKeyPath in IopQueryDeviceCapabilities (by me).

svn path=/trunk/; revision=74495

6 years ago[NTOS]: Code formatting + free the memory in the reverse order from how it was allocated.
Hermès Bélusca-Maïto [Mon, 8 May 2017 00:51:44 +0000 (00:51 +0000)]
[NTOS]: Code formatting + free the memory in the reverse order from how it was allocated.

svn path=/trunk/; revision=74494

6 years ago[NTOS]: Capture the counted BaseDllName unicode string into a local NULL-terminated...
Hermès Bélusca-Maïto [Sun, 7 May 2017 18:15:12 +0000 (18:15 +0000)]
[NTOS]: Capture the counted BaseDllName unicode string into a local NULL-terminated buffer before calling wcsrchr on it (actually I think it would be better to create & use a similar function that takes counted strings in input).
Also use 'L' prefix for wide characters and UNICODE_NULL for string terminator.
Patch by Lesan Ilie.
CORE-13208 #resolve

svn path=/trunk/; revision=74493

6 years ago[NTOS]: Code formatting changes only.
Hermès Bélusca-Maïto [Sun, 7 May 2017 18:12:18 +0000 (18:12 +0000)]
[NTOS]: Code formatting changes only.

svn path=/trunk/; revision=74492

6 years ago[NTOS]: Fix a potential memory leak.
Hermès Bélusca-Maïto [Sun, 7 May 2017 17:50:18 +0000 (17:50 +0000)]
[NTOS]: Fix a potential memory leak.
- If one of the ZwSetValueKey function fails, 'Node->ServiceName.Buffer' is leaked.
- Also use 'L' prefix for wide characters.
Patch by Lesan Ilie, thanks!
- Use "P(C)WSTR" instead of win32 "LP(C)WSTR" string pointer types (by me).
CORE-13207 #resolve

svn path=/trunk/; revision=74491

6 years ago[NTDLL]
Thomas Faber [Sat, 6 May 2017 17:51:26 +0000 (17:51 +0000)]
[NTDLL]
- Implement user-mode version of RtlWalkFrameChain (mostly as a copy of the kernel version). Now RtlCaptureStackBackTrace actually, you know, captures stack back-traces.

svn path=/trunk/; revision=74490

6 years ago[KMTESTS:RTL]
Thomas Faber [Sat, 6 May 2017 15:29:56 +0000 (15:29 +0000)]
[KMTESTS:RTL]
- Add a test for RtlWalkFrameChain and RtlCaptureStackBackTrace

svn path=/trunk/; revision=74489

6 years ago[INTL]
Eric Kohl [Sat, 6 May 2017 14:41:50 +0000 (14:41 +0000)]
[INTL]
- Get rid of the individual getter funtions. Use GetSelectedComboBoxIndex for all CBS_DROPDOWNLIST comboboxes and GetSelectedComboBoxText for all CBS_DROPDOWN comboboxes.
- Check the relevant settings only!
- Rename SetXxxSettings to GetXxxSettings because it is a getter function.
- Handle the bogus WM_COMMAND/EN_CHANGE message that is sent when the IDC_SECONDYEAR_EDIT edit control is initialized. Controls should NEVER send notifications when they are modified programmatically! :-/

svn path=/trunk/; revision=74488

6 years ago[INTL]
Eric Kohl [Sat, 6 May 2017 13:43:03 +0000 (13:43 +0000)]
[INTL]
Changed locale options doesn't reload correctly before next reboot.
- Added SetNumberSetting, SetCurrencySetting, SetDateSetting and SetTimeSetting functions to get and check values.
- Don't directly change pGlobalData.
- Post WM_WININICHANGE after all changes have been applied.
Based on a patch by Katayama Hirofumi MZ.
CORE-10170

svn path=/trunk/; revision=74487

6 years ago[WIN32K:NTGDI]
Thomas Faber [Sat, 6 May 2017 12:18:21 +0000 (12:18 +0000)]
[WIN32K:NTGDI]
- Avoid using floating point operations in kernel mode.
CORE-10893

svn path=/trunk/; revision=74486

6 years ago[MMSYS]
Thomas Faber [Sat, 6 May 2017 10:14:29 +0000 (10:14 +0000)]
[MMSYS]
- Simplify code by using windowsx.h. Patch by Katayama Hirofumi MZ.
CORE-12903

svn path=/trunk/; revision=74485

6 years ago[MMSYS]
Thomas Faber [Sat, 6 May 2017 09:27:32 +0000 (09:27 +0000)]
[MMSYS]
- Make browse dialog title and filter localizable. Based on a patch by Katayama Hirofumi MZ.
CORE-12903

svn path=/trunk/; revision=74484

6 years ago[MMSYS]
Thomas Faber [Sat, 6 May 2017 08:43:56 +0000 (08:43 +0000)]
[MMSYS]
- Pass byte counts to RegQueryValueEx instead of character counts. Based on a patch by Katayama Hirofumi MZ.
CORE-12903

svn path=/trunk/; revision=74483

6 years ago[MMSYS]
Thomas Faber [Sat, 6 May 2017 08:22:50 +0000 (08:22 +0000)]
[MMSYS]
Patch by Katayama Hirofumi MZ:
- Use _countof where appropriate
- Prefer sizeof(variable) to sizeof(TYPE)
CORE-12903

svn path=/trunk/; revision=74482

6 years ago[COMCTL32]
Thomas Faber [Fri, 5 May 2017 19:23:04 +0000 (19:23 +0000)]
[COMCTL32]
- Fix heap memory leak in BUTTON_DrawTextCallback
CORE-13190

svn path=/trunk/; revision=74481

6 years ago[COMCTL32] Toolbar: Use DrawThemeText when themes are enabled. CORE-12789
Giannis Adamopoulos [Fri, 5 May 2017 10:55:12 +0000 (10:55 +0000)]
[COMCTL32] Toolbar: Use DrawThemeText when themes are enabled. CORE-12789

svn path=/trunk/; revision=74480

6 years ago[SHELL32] -CMenuDeskBar: Handle WM_NCPAINT and paint the border with the correct...
Giannis Adamopoulos [Fri, 5 May 2017 09:01:15 +0000 (09:01 +0000)]
[SHELL32] -CMenuDeskBar: Handle WM_NCPAINT and paint the border with the correct color when it has the flat style.

svn path=/trunk/; revision=74479

6 years ago[KERNEL32_APITEST]
Thomas Faber [Thu, 4 May 2017 16:45:42 +0000 (16:45 +0000)]
[KERNEL32_APITEST]
- Fix a broken test name. APITests can not have names already used by Wine tests!  ... they should be named after APIs, anyway...

svn path=/trunk/; revision=74478

6 years ago[NDK]: Guard the Bitmap API prototypes in a NTOS_MODE_USER, so that a driver that...
Hermès Bélusca-Maïto [Thu, 4 May 2017 16:12:52 +0000 (16:12 +0000)]
[NDK]: Guard the Bitmap API prototypes in a NTOS_MODE_USER, so that a driver that includes both wdm.h and ndk/rtlfuncs.h for whatever reason does not include twice the bitmap API.
This in particular fixes compilation under x64 due to the fact that, in x64, one of these API is declared (force)inline and the compiler complained that this function already had a body.

svn path=/trunk/; revision=74477

6 years ago[USBD.SYS]: Exports:
Hermès Bélusca-Maïto [Thu, 4 May 2017 15:46:09 +0000 (15:46 +0000)]
[USBD.SYS]: Exports:
- The three C-decorated exports _USBD_CreateConfigurationRequestEx@8, _USBD_ParseConfigurationDescriptorEx@28 and _USBD_ParseDescriptors@16 are only exported in the i386 version of the driver (not present in x64, checked on WinXP x64).
  This fixes warnings in ReactOS x64 compilation.
- Add (commented out) the remaining exports (without their parameters) that need to be implemented and exported.

svn path=/trunk/; revision=74476

6 years ago[KERNEL32_APITEST]: Internationalization console tests by Katayama Hirofumi MZ.
Hermès Bélusca-Maïto [Thu, 4 May 2017 15:39:50 +0000 (15:39 +0000)]
[KERNEL32_APITEST]: Internationalization console tests by Katayama Hirofumi MZ.
Passes on Win2k3 (either are skipped because either Russian or Japanese locales or codepages are absent, or are passed OK), but not on ReactOS yet. They are committed as reference for future work.
CORE-12451

svn path=/trunk/; revision=74475

6 years ago[BROWSEUI_APITEST] -Add tests for SHExplorerParseCmdLine for CORE-12882.
Giannis Adamopoulos [Thu, 4 May 2017 15:15:45 +0000 (15:15 +0000)]
[BROWSEUI_APITEST] -Add tests for SHExplorerParseCmdLine for CORE-12882.

svn path=/trunk/; revision=74474

6 years ago[SHELL32_APITEST] -Add some tests for SHParseDisplayName for CORE-12882.
Giannis Adamopoulos [Thu, 4 May 2017 15:05:10 +0000 (15:05 +0000)]
[SHELL32_APITEST] -Add some tests for SHParseDisplayName for CORE-12882.

svn path=/trunk/; revision=74473

6 years ago[CONSOLE.CPL]: Spanish translation update by Javier Fernandez, thanks!
Hermès Bélusca-Maïto [Thu, 4 May 2017 14:21:41 +0000 (14:21 +0000)]
[CONSOLE.CPL]: Spanish translation update by Javier Fernandez, thanks!
CORE-13187 #resolve

svn path=/trunk/; revision=74472

6 years ago[CONSOLE.CPL]: Fix the console props color buttons (was broken by r74468). Noted...
Hermès Bélusca-Maïto [Thu, 4 May 2017 14:18:14 +0000 (14:18 +0000)]
[CONSOLE.CPL]: Fix the console props color buttons (was broken by r74468). Noted by Katayama Hirofumi MZ, thanks!
CORE-13186 #resolve

svn path=/trunk/; revision=74471

6 years ago[RAPPS]
Thomas Faber [Thu, 4 May 2017 07:09:18 +0000 (07:09 +0000)]
[RAPPS]
- Display download URL in information panel. Patch by Alexander Shaposhnikov.
CORE-12442 #resolve

svn path=/trunk/; revision=74470

6 years ago[CONSOLE.CPL]: Rewrite the way we deal with console font samples in the console prope...
Hermès Bélusca-Maïto [Wed, 3 May 2017 23:56:35 +0000 (23:56 +0000)]
[CONSOLE.CPL]: Rewrite the way we deal with console font samples in the console properties dialog:
- Remove the font helper functions that were already moved into concfg/font.c in r74462, and use the latter instead.
- Use a double list for listing the available font sizes for a given face:
  * a ListBox for raster fonts;
  * a ComboBox for TrueType fonts, allowing the user to specify a custom size.
  The raster ListBox is wrapped using the LIST_CTL structure so that we can use
  the bisection functions on it.
- Allow the user to specify TrueType font size either in pixels or in points. Raster font sizes however are always in pixels.
- Try to remember the nearest font size across different selected face changes.
- Try to support custom-sized TrueType fonts (using the ComboBox's edit field). May need more improvements!
- Retrieve the correct character cell height & width size in pixels when selecting a font (especially when it's a TrueType one).
- We now support bold console fonts too, see CORE-13122 (thanks Katayama!).
- Remove the commented-out "temporary code for future reference".
- Use a global cached font "hCurrentFont" that gets initialized when the console properties applet is created,
  so that we now can have a correct font in the screen samples when one directly views e.g. the "Color" tab,
  without going first in the "Font" tab. This current font is of course updated whenever one changes the font settings.

Tested with success on Windows 2003, Windows 7 and on ReactOS.

CORE-13122 CORE-13182 #resolve

svn path=/trunk/; revision=74469

6 years ago[CONSOLE.CPL]: Minor code refactoring (cont.):
Hermès Bélusca-Maïto [Wed, 3 May 2017 23:05:25 +0000 (23:05 +0000)]
[CONSOLE.CPL]: Minor code refactoring (cont.):
- Use 'hDlg' for the dialog window handle variable (instead of hwndDlg), as already done in other parts of the code;
- Use our regular formatting for function prototypes;
- Use explicit unicode functions;

In addition:
- Correctly check for the dialog controls notifications (within WM_COMMAND message);
- Update the current code page when the code page combobox selection changes, but only notify the property sheet of the change when the combobox contents is validated (either the user pressed ENTER in some way, or the combobox lost its focus).

svn path=/trunk/; revision=74468

6 years ago[SHELL32] -CMenuBand: Correctly get the setting for flat menus. CORE-8925
Giannis Adamopoulos [Wed, 3 May 2017 21:49:38 +0000 (21:49 +0000)]
[SHELL32] -CMenuBand: Correctly get the setting for flat menus. CORE-8925

svn path=/trunk/; revision=74467

6 years ago[CONSOLE.CPL]: Minor code refactoring:
Hermès Bélusca-Maïto [Wed, 3 May 2017 20:35:12 +0000 (20:35 +0000)]
[CONSOLE.CPL]: Minor code refactoring:
- Move the bisection functions into their own source file, and make them a bit more general so that they can be used on other types of list structures than win32 combo-boxes.
- Adjust the code in options.c to reflect those changes.

svn path=/trunk/; revision=74466

6 years ago[CONSOLE.CPL]: Harmonize most of the resources (sizes of dialog controls for some...
Hermès Bélusca-Maïto [Wed, 3 May 2017 20:23:12 +0000 (20:23 +0000)]
[CONSOLE.CPL]: Harmonize most of the resources (sizes of dialog controls for some dialogs), and add some new controls in the font dialog that will be used soon.
To translators: Please check that I haven't broken any translations! :)
CORE-13182

svn path=/trunk/; revision=74465

6 years ago[CONSRV]: Improvements for console font support (part 2):
Hermès Bélusca-Maïto [Wed, 3 May 2017 20:13:23 +0000 (20:13 +0000)]
[CONSRV]: Improvements for console font support (part 2):
- Use the font functions from the concfg library (see r74462) to create a new console font & retrieve its metrics, inspired by the suggestions from Katayama Hirofumi MZ in CORE-12451 and CORE-13122;
- Use string-safe functions to copy the font names into the fixed-size buffers;
- Use explicit UNICODE calls to GetObject and CreateFontIndirect.
Related to CORE-13182.

svn path=/trunk/; revision=74464

6 years ago[CONSRV]: Use string-safe functions to copy the font names into the fixed-size buffers.
Hermès Bélusca-Maïto [Wed, 3 May 2017 19:57:28 +0000 (19:57 +0000)]
[CONSRV]: Use string-safe functions to copy the font names into the fixed-size buffers.

svn path=/trunk/; revision=74463

6 years ago[CONCFG]: Diverse improvements/additions for the console configuration library. CORE...
Hermès Bélusca-Maïto [Wed, 3 May 2017 19:47:18 +0000 (19:47 +0000)]
[CONCFG]: Diverse improvements/additions for the console configuration library. CORE-13182
- Use string-safe functions to copy the font names into the fixed-size buffers;
- Modify some default settings;
- Add a set of console font manipulation functions, to be used later by both the console applet console.cpl and by CONSRV.
  Some of these functions come from r74365 with minor improvements (see CORE-12451 too), others are based from a patch
  by Katayama Hirofumi MZ from CORE-13122, and the rest are needed for an upcoming commit for console.cpl.
- Add PCH support in concfg.
- Minor code formatting: Use our regular formatting for function prototypes.

svn path=/trunk/; revision=74462

6 years ago[ISOHYBRID]
Colin Finck [Wed, 3 May 2017 15:32:33 +0000 (15:32 +0000)]
[ISOHYBRID]
Patch all our ISOs (bootcd, bootcdregtest, livecd, hybridcd) with isohybrid in order to make them bootable from HDDs or any kind of USB drives.
The added MBR at the beginning of each ISO doesn't cause any harm for normal CD booting anymore after my patch in r74460.
There is also no need for the dedicated isohybrid targets anymore.

Our ISOMBR master boot record now successfully loads our ISOBOOT boot sector. ISOBOOT loads FreeLdr and indicates that we're booting from HDD, so that FreeLdr can successfully load the kernel.
We then bugcheck in the kernel with either 0x0000007B (INACCESSIBLE_BOOT_DEVICE) using bootcd or 0x0000006B (PROCESS1_INITIALIZATION_FAILED) using livecd.
Testcase is:
  qemu-system-i386 -m 512 -hda bootcd_or_livecd.iso

Needs more investigation, but these are separate bugs and I consider CORE-12648 fixed.

svn path=/trunk/; revision=74461

6 years ago[FREELDR]
Colin Finck [Wed, 3 May 2017 14:53:57 +0000 (14:53 +0000)]
[FREELDR]
Set BootPartition (DH) to 0xFF in isoboot.S when booting from CD.
Then check for that 0xFF value in FreeLdr to unambiguously detect CD booting instead of using BIOS functions (which don't work reliably on broken BIOSes) or checking for an MBR (which doesn't work on hybrid ISOs).

CORE-12692

svn path=/trunk/; revision=74460

6 years ago[UXTHEME] -Use GdiDrawStream in UXTHEME_DrawImageGlyph and UXTHEME_DrawImageBackground.
Giannis Adamopoulos [Wed, 3 May 2017 11:13:23 +0000 (11:13 +0000)]
[UXTHEME] -Use GdiDrawStream in UXTHEME_DrawImageGlyph and UXTHEME_DrawImageBackground.

svn path=/trunk/; revision=74457

6 years ago[GDI32] -Add a public undocgdi.h file to keep the definitions for undocumented export...
Giannis Adamopoulos [Wed, 3 May 2017 10:55:54 +0000 (10:55 +0000)]
[GDI32] -Add a public undocgdi.h file to keep the definitions for undocumented exports. For now it only contains GdiDrawStream.

svn path=/trunk/; revision=74452

6 years ago[NTOSKNRL]
Pierre Schweitzer [Tue, 2 May 2017 21:32:20 +0000 (21:32 +0000)]
[NTOSKNRL]
Misc fixes in NtQueryDirectoryFile():
- Don't leak auxbuffer
- Don't allow two completion routines

svn path=/trunk/; revision=74451

6 years ago[FASTFAT]
Thomas Faber [Tue, 2 May 2017 19:33:14 +0000 (19:33 +0000)]
[FASTFAT]
- Add support for FILE_DELETE_ON_CLOSE
CORE-6931 #resolve

svn path=/trunk/; revision=74450

6 years ago[NTOS:MM]
Thomas Faber [Tue, 2 May 2017 17:18:37 +0000 (17:18 +0000)]
[NTOS:MM]
- Avoid a file object reference leak in MmCreateSection.
CORE-6931

svn path=/trunk/; revision=74449

6 years ago[SHELL32] -CDefView: Hide the drag image at drop.
Giannis Adamopoulos [Tue, 2 May 2017 14:01:07 +0000 (14:01 +0000)]
[SHELL32] -CDefView: Hide the drag image at drop.

svn path=/trunk/; revision=74448

6 years ago[NTOS:MM]
Thomas Faber [Tue, 2 May 2017 11:11:39 +0000 (11:11 +0000)]
[NTOS:MM]
- When mapping a view of the physical memory section, don't check for BaseAddress/SectionOffset alignment. Instead, prevent user mode mappings of views beyond the highest physical page. Fixes flakiness in kmtest:MmSection
CORE-13113 #resolve

svn path=/trunk/; revision=74447

6 years ago[KMTESTS:MM]
Thomas Faber [Tue, 2 May 2017 09:02:10 +0000 (09:02 +0000)]
[KMTESTS:MM]
Add some more tests for physical memory sections:
- Show that any alignment for SectionOffset/ViewSize is allowed. It will get automatically fixed up to page alignment
- Show that kernel mode can map views beyond the highest physical page, but user mode cannot
CORE-13113

svn path=/trunk/; revision=74446

6 years ago[NTOS:IO]
Thomas Faber [Tue, 2 May 2017 08:18:30 +0000 (08:18 +0000)]
[NTOS:IO]
- Print the error status and message in IoRaiseInformationalHardError
CORE-13174 #resolve

svn path=/trunk/; revision=74445

6 years ago[CMD]
Pierre Schweitzer [Mon, 1 May 2017 21:14:38 +0000 (21:14 +0000)]
[CMD]
Fix and simplify implementation of "IF EXIST":
- Don't make any difference between wildcard search and normal search
- This fixes handling DOS devices search (ie, IF EXIST C:\ReactOS\NUL now works)
- This fixes handling pagefile.sys without requiring specifing rights
- Also fix handling directory search, terminated with a \

CORE-11784

svn path=/trunk/; revision=74444

6 years ago[COMCTL32] Fix use of uninitialized variable.
Giannis Adamopoulos [Mon, 1 May 2017 18:56:03 +0000 (18:56 +0000)]
[COMCTL32] Fix use of uninitialized variable.

svn path=/trunk/; revision=74443

6 years ago[INTL]
Eric Kohl [Mon, 1 May 2017 17:05:31 +0000 (17:05 +0000)]
[INTL]
Added initialization of IDC_CURRENCYGRPNUM.
Patch by Katayama Hirofumi MZ.
CORE-10170

svn path=/trunk/; revision=74442

6 years ago[BROWSEUI] Don't leak the image lists created by CAddressBand and CToolsBand.
Giannis Adamopoulos [Mon, 1 May 2017 13:43:22 +0000 (13:43 +0000)]
[BROWSEUI] Don't leak the image lists created by CAddressBand and CToolsBand.

svn path=/trunk/; revision=74441

6 years ago[COMCTL32] -ImageList: Don't leak the DC returned by saturate_image.
Giannis Adamopoulos [Mon, 1 May 2017 13:40:57 +0000 (13:40 +0000)]
[COMCTL32] -ImageList: Don't leak the DC returned by saturate_image.

svn path=/trunk/; revision=74440

6 years ago[TRANSLATION]
Eric Kohl [Mon, 1 May 2017 13:09:31 +0000 (13:09 +0000)]
[TRANSLATION]
Japanese NLS info.
Patch by Katayama Hirofumi MZ.
CORE-13164

svn path=/trunk/; revision=74439

6 years ago[COMCTL32] -Rebar: Fix a region handle leak when themes are enabled.
Giannis Adamopoulos [Mon, 1 May 2017 12:44:24 +0000 (12:44 +0000)]
[COMCTL32] -Rebar: Fix a region handle leak when themes are enabled.

svn path=/trunk/; revision=74438

6 years ago[EXPLORER] CTrayClockWnd: Fix a leak of font handles. CORE-13155
Giannis Adamopoulos [Mon, 1 May 2017 09:35:03 +0000 (09:35 +0000)]
[EXPLORER] CTrayClockWnd: Fix a leak of font handles. CORE-13155

svn path=/trunk/; revision=74437

6 years ago[NTOS:IO]
Thomas Faber [Sun, 30 Apr 2017 19:24:53 +0000 (19:24 +0000)]
[NTOS:IO]
- Fix some extremely broken casts

svn path=/trunk/; revision=74436

6 years ago[WIN32K]
Thomas Faber [Sun, 30 Apr 2017 18:41:56 +0000 (18:41 +0000)]
[WIN32K]
- Check for null members when cleaning up DCs and brushes. Fixes crashes in some failure cases when running out of GDI handles.
CORE-13155

svn path=/trunk/; revision=74435

6 years ago[INTL]
Eric Kohl [Sun, 30 Apr 2017 15:39:41 +0000 (15:39 +0000)]
[INTL]
- Get rid of alloca, malloc and free.
- Always check the return values of HeapAlloc.
- Rename fUserLocaleChanged to bUserLocaleChanged and fGeoIdChanged to bGeoIdChanged.
- Use WCHAR instead of TCHAR.
- Fix indentation and coding style.
- Remove setupreg.c because it is an unused copy of misc.c.

svn path=/trunk/; revision=74434

6 years ago[LOCALSPL] [SPOOLSV] [WINSPOOL]
Colin Finck [Sun, 30 Apr 2017 15:12:53 +0000 (15:12 +0000)]
[LOCALSPL] [SPOOLSV] [WINSPOOL]
- Refactor the code returning PRINTER_INFO_* yet another time to support both EnumPrinters and GetPrinter calls.
- Implement support for PRINTER_INFO_1 through PRINTER_INFO_9 as well as the mostly unknown PRINTER_INFO_STRESS (level 0) structure and return as much information as we can.
- Implement GetPrinterW / LocalGetPrinter.

The Printers Shell folder in Explorer now shows our "Dummy Printer on LPT1" and we pass all 291 winspool:EnumPrinters API tests :)

svn path=/trunk/; revision=74433

6 years ago[KERNEL32_APITEST]
Pierre Schweitzer [Sun, 30 Apr 2017 11:43:04 +0000 (11:43 +0000)]
[KERNEL32_APITEST]
- Refactor a bit tests, to split more logically tests
- Fix a bug in tests
- Add new tests for MountMgr showing our storage stack doesn't behave as expected

svn path=/trunk/; revision=74432

6 years ago[BOOTDATA]
Eric Kohl [Sat, 29 Apr 2017 17:17:10 +0000 (17:17 +0000)]
[BOOTDATA]
Make service display names and descriptions translatable.
CORE-11855

svn path=/trunk/; revision=74431

6 years ago[CDFS]
Pierre Schweitzer [Fri, 28 Apr 2017 19:32:44 +0000 (19:32 +0000)]
[CDFS]
Fix returned data handling on directory enumeration.
Patch by Giannis Adamopoulos

CORE-13143

svn path=/trunk/; revision=74430

6 years ago[COMCTL32] -Add v5 and v6 manifests in livecd.
Giannis Adamopoulos [Fri, 28 Apr 2017 17:11:46 +0000 (17:11 +0000)]
[COMCTL32] -Add v5 and v6 manifests in livecd.

svn path=/trunk/; revision=74429

6 years ago[NtGDI]
James Tabor [Thu, 27 Apr 2017 19:20:09 +0000 (19:20 +0000)]
[NtGDI]
- Use internal function for setting brush origin. Related to CORE-13110.

svn path=/trunk/; revision=74422

6 years ago[NtGDI]
James Tabor [Thu, 27 Apr 2017 17:53:03 +0000 (17:53 +0000)]
[NtGDI]
- Update DC attributes while internally setting brush origin. Related to CORE-13110.

svn path=/trunk/; revision=74421

6 years ago[WIN32SS] Fix returning an uninitialized variable. Patch by Victor Martinez Calvo...
Mark Jansen [Thu, 27 Apr 2017 15:37:08 +0000 (15:37 +0000)]
[WIN32SS] Fix returning an uninitialized variable. Patch by Victor Martinez Calvo. CID 1341417, CORE-11027 #comment Thanks!

svn path=/trunk/; revision=74420

6 years ago[GDI32]
Thomas Faber [Thu, 27 Apr 2017 08:59:29 +0000 (08:59 +0000)]
[GDI32]
- Fix last error value returned from GdiSelectPen for invalid DCs. Fixes the last test failure in gdi32:gdiobj. Patch by Katayama Hirofumi MZ.
CORE-13132 #resolve

svn path=/trunk/; revision=74419

6 years ago[EVENTVWR]
Thomas Faber [Thu, 27 Apr 2017 00:23:04 +0000 (00:23 +0000)]
[EVENTVWR]
- Avoid two cases of uninitialized variable use in GetEventUserName. Based on a patch by Víctor Martínez Calvo. CID 1401250
CORE-12798 #resolve

svn path=/trunk/; revision=74418

6 years ago[EVENTVWR]
Thomas Faber [Thu, 27 Apr 2017 00:17:08 +0000 (00:17 +0000)]
[EVENTVWR]
- Make user name caching actually work
CORE-12798

svn path=/trunk/; revision=74417

6 years ago[CMD]: Improvements for the CHCP command.
Hermès Bélusca-Maïto [Wed, 26 Apr 2017 22:29:07 +0000 (22:29 +0000)]
[CMD]: Improvements for the CHCP command.
- Display the informative CP-change message on stdout, using the *output* code page (and not the input CP);
- Correctly update the local codepage cache;
- Display the informative CP-change message when the CP change succeeded;
- Add source comments + informative TODO for what remains to be done.

svn path=/trunk/; revision=74416

6 years ago[BOOTDATA]
Eric Kohl [Wed, 26 Apr 2017 21:21:02 +0000 (21:21 +0000)]
[BOOTDATA]
Make the timezone names translatable.
CORE-11855

svn path=/trunk/; revision=74415

6 years ago[KERNEL32]: Add/update localized codepage display names.
Hermès Bélusca-Maïto [Wed, 26 Apr 2017 20:31:54 +0000 (20:31 +0000)]
[KERNEL32]: Add/update localized codepage display names.
- Slightly update the description of CP 28599;
- Add descriptions for CPs 28600, 28603, 28604 and 28606;
- Add CP 856 "OEM - Hebrew PC" (which differs from OEM Hebrew CP 862).
Note that while we also have codepages 424, 878 and 1006, I don't add their description because:
- CP 424 is actually CP 20424 "IBM EBCDIC - Hebrew" on Windows (documented in the resource files);
- CP 878 is actually CP 20866 "Russian - KOI8" on Windows (documented in the resource files);
- CP 1006 seems to be "IBM Arabic" according to Wine, but I don't know its corresponding number on Windows.

svn path=/trunk/; revision=74414

6 years ago[KERNEL32]: Little improvements/fixes for GetCPInfoExW and GetGeoInfoW:
Hermès Bélusca-Maïto [Wed, 26 Apr 2017 17:38:57 +0000 (17:38 +0000)]
[KERNEL32]: Little improvements/fixes for GetCPInfoExW and GetGeoInfoW:
- Rework GetLocalisedText helper such that it looks more like LoadStringW. Also, if the string is not found (either because there is no associated string table, or because its resource length is zero), then return zero.
  Otherwise we return the correct number of characters copied into the user buffer, not counting the NULL terminator.
  This fixes the blank strings showing in the list of codepage user-friendly names in the console properties dialog.
- Simplify the code of NLS_GetGeoFriendlyName: we can directly use the user-provided buffer to retrieve the string.
Addendum to r65157.
CORE-13130 #resolve

svn path=/trunk/; revision=74413

6 years ago[KERNEL32]: Add the Brunei in the list of localized countries.
Hermès Bélusca-Maïto [Wed, 26 Apr 2017 17:10:51 +0000 (17:10 +0000)]
[KERNEL32]: Add the Brunei in the list of localized countries.
Translators, please localize the name!

svn path=/trunk/; revision=74412

6 years ago[UXTHEME] -Fix some resource leaks.
Giannis Adamopoulos [Wed, 26 Apr 2017 13:55:19 +0000 (13:55 +0000)]
[UXTHEME] -Fix some resource leaks.

svn path=/trunk/; revision=74411

6 years ago[COMMAND]: Disable COMMAND.COM debugging messages by default.
Hermès Bélusca-Maïto [Wed, 26 Apr 2017 13:41:43 +0000 (13:41 +0000)]
[COMMAND]: Disable COMMAND.COM debugging messages by default.
Disable again this #define if you want to get the dbg messages back.
CORE-10710

svn path=/trunk/; revision=74410

6 years ago[USBOHCI]
Thomas Faber [Wed, 26 Apr 2017 10:54:34 +0000 (10:54 +0000)]
[USBOHCI]
- Not building before committing is also a hack
CORE-9224

svn path=/trunk/; revision=74409

6 years ago[USBEHCI][USBOHCI]
Thomas Faber [Wed, 26 Apr 2017 10:53:32 +0000 (10:53 +0000)]
[USBEHCI][USBOHCI]
- Touch the virtual address of DMA buffers before calling MmGetPhysicalAddress on them. This ensures page directories are correctly set up for the current process context, and fixes random DMA operation failures ("MM:MmGetPhysicalAddressFailed"). This is not a hack -- using MmGetPhysicalAddress for DMA in the first place is.
CORE-9224 #resolve

svn path=/trunk/; revision=74408

6 years ago[UXTHEME] -Implement the tab background texture. NOTE: A hack was used to go around...
Giannis Adamopoulos [Wed, 26 Apr 2017 09:28:35 +0000 (09:28 +0000)]
[UXTHEME] -Implement the tab background texture. NOTE: A hack was used to go around the problem that SetBrushOrgEx doesn't really work. CORE-12978

svn path=/trunk/; revision=74407

6 years ago[COMCTL32]
Giannis Adamopoulos [Tue, 25 Apr 2017 11:19:22 +0000 (11:19 +0000)]
[COMCTL32]
- Button, Trakbar: Send WM_CTLCOLORBTN or WM_CTLCOLORSTATIC and use their return value to paint the control despite the fact that DrawThemeParentBackground was called as well.
Part of the fix for CORE-12978

svn path=/trunk/; revision=74406

6 years ago[CONSOLE.CPL]: Simplify some parts of font.c code.
Hermès Bélusca-Maïto [Mon, 24 Apr 2017 17:01:07 +0000 (17:01 +0000)]
[CONSOLE.CPL]: Simplify some parts of font.c code.
- Use a helper function "AddFontToList" to add font names into the font list;
- Use string-safe functions where needed.

svn path=/trunk/; revision=74405

6 years ago[WIN32K:ENG]
Thomas Faber [Mon, 24 Apr 2017 16:28:04 +0000 (16:28 +0000)]
[WIN32K:ENG]
- In PDEVOBJ_vRefreshModeList, restore the current mode pointer, ppdev->pdmwDev, to a valid value.
CORE-13097 #resolve

svn path=/trunk/; revision=74404

6 years ago[USER32]
Thomas Faber [Mon, 24 Apr 2017 15:04:00 +0000 (15:04 +0000)]
[USER32]
Fix heap corruption in EnumDisplaySettingsExA/W:
- Do not overwrite the user-provided buffer size in dmDriverExtra
- Fix broken pointer arithmetic
CORE-13097

svn path=/trunk/; revision=74403

6 years ago[ACCESS]: Fix french el-typo, noticed by Kyle Katarn. Thanks!
Hermès Bélusca-Maïto [Mon, 24 Apr 2017 11:17:10 +0000 (11:17 +0000)]
[ACCESS]: Fix french el-typo, noticed by Kyle Katarn. Thanks!
CORE-12482

svn path=/trunk/; revision=74402

6 years ago[WININET]
Thomas Faber [Mon, 24 Apr 2017 10:07:39 +0000 (10:07 +0000)]
[WININET]
- Silence Firefox/Safari debug spam
CORE-12853 CORE-12128 CORE-11135

svn path=/trunk/; revision=74401

6 years ago[NTOS:MM]
Thomas Faber [Mon, 24 Apr 2017 09:45:03 +0000 (09:45 +0000)]
[NTOS:MM]
- In MiFlushTbAndCapture, only print a fixme if we actually need to do something.
CORE-12074 #resolve

svn path=/trunk/; revision=74400

6 years ago[CONSOLE]
Thomas Faber [Mon, 24 Apr 2017 07:19:41 +0000 (07:19 +0000)]
[CONSOLE]
- Fix build
CORE-12451

svn path=/trunk/; revision=74399

6 years ago[CONSOLE.CPL]: Addendum to r74397: Fix a cast.
Hermès Bélusca-Maïto [Mon, 24 Apr 2017 00:32:10 +0000 (00:32 +0000)]
[CONSOLE.CPL]: Addendum to r74397: Fix a cast.

svn path=/trunk/; revision=74398