reactos.git
2 years ago[CRYPTUI] Fix all MSVC *.rc warnings RC4206 CORE-18017
Joachim Henze [Wed, 26 Jan 2022 02:23:00 +0000 (03:23 +0100)]
[CRYPTUI] Fix all MSVC *.rc warnings RC4206 CORE-18017

warning RC4206 : title string too long; truncated at 256
by providing shorter translations.
We had 24 such warnings in this module on master head.

2 years ago[USER32] Fix uninitialized cbTotal
Katayama Hirofumi MZ [Tue, 25 Jan 2022 23:14:59 +0000 (08:14 +0900)]
[USER32] Fix uninitialized cbTotal

CORE-18025

2 years ago[TASKMGR] Fix a heap corruption bug (#4311)
Valerij Zaporogeci [Tue, 25 Jan 2022 14:49:46 +0000 (16:49 +0200)]
[TASKMGR] Fix a heap corruption bug (#4311)

Improper adjustment of the array index in graphctl.c, introduced in PR #4141 lead to an off-by-one heap corruption.

2 years ago[USER32] Fix release build C4700 CORE-16287
Katayama Hirofumi MZ [Tue, 25 Jan 2022 12:57:47 +0000 (21:57 +0900)]
[USER32] Fix release build C4700 CORE-16287

2 years ago[SHELL32] CCopyToMenu/CMoveToMenu: Check if this_ is NULL
Katayama Hirofumi MZ [Tue, 25 Jan 2022 12:08:14 +0000 (21:08 +0900)]
[SHELL32] CCopyToMenu/CMoveToMenu: Check if this_ is NULL

2 years ago[USER32] Follow-up of #4262 (a47590c) (#4312)
Katayama Hirofumi MZ [Tue, 25 Jan 2022 11:41:00 +0000 (20:41 +0900)]
[USER32] Follow-up of #4262 (a47590c) (#4312)

Display icons/cursors correctly without hungup. CORE-16287

2 years ago[SHELL32] Fix assertion failure in CMenuToolbars
Katayama Hirofumi MZ [Tue, 25 Jan 2022 02:49:27 +0000 (11:49 +0900)]
[SHELL32] Fix assertion failure in CMenuToolbars

CORE-17505

2 years ago[NTOS:KE] Remove all checks for x87 not being present 4246/head 4285/head
Victor Perevertkin [Sat, 15 Jan 2022 01:15:05 +0000 (04:15 +0300)]
[NTOS:KE] Remove all checks for x87 not being present

2 years ago[NTOS:KE] Add a check for unsupported CPU features on i586
Victor Perevertkin [Sat, 15 Jan 2022 00:42:59 +0000 (03:42 +0300)]
[NTOS:KE] Add a check for unsupported CPU features on i586

Currently, these features are vital for the kernel:
- CPUID instruction
- CMPXCHG8B instruction
- TSC aka Time Stamp Counter

All of that have to be present on i586

2 years ago[NTOS:KE] Move CPU features detection to a separate function on i586
Victor Perevertkin [Sat, 15 Jan 2022 00:24:55 +0000 (03:24 +0300)]
[NTOS:KE] Move CPU features detection to a separate function on i586

2 years ago[SHELL32] Enable _DEBUG and fix assertion failures (#4307)
Katayama Hirofumi MZ [Mon, 24 Jan 2022 18:42:46 +0000 (03:42 +0900)]
[SHELL32] Enable _DEBUG and fix assertion failures (#4307)

Improve debuggability. Fix "WorkerW" window class conflict.
- Enable _DEBUG macro if debugging, in order to enable ATLASSERT macro.
- Fix assertion failures.
- Add SHCreateDefaultWorkerWindow helper function and CWorkerTraits, then use them.
- Don't create the broker and server windows by themselves, but subclass.
CORE-17505, CORE-13950

2 years ago[RAPPS] Enable _DEBUG and fix assertion failures
Katayama Hirofumi MZ [Mon, 24 Jan 2022 01:50:26 +0000 (10:50 +0900)]
[RAPPS] Enable _DEBUG and fix assertion failures

CORE-17505

2 years ago[EXPLORER] Enable _DEBUG and fix assertion failures (#4306)
Katayama Hirofumi MZ [Mon, 24 Jan 2022 01:26:13 +0000 (10:26 +0900)]
[EXPLORER] Enable _DEBUG and fix assertion failures (#4306)

- Enable _DEBUG if debugging.
- Fix assertion failures.
CORE-18013

2 years ago[RAPPS] Update outdated README regarding size CORE-18018
Joachim Henze [Sun, 23 Jan 2022 21:03:08 +0000 (22:03 +0100)]
[RAPPS] Update outdated README regarding size CORE-18018

2 years ago[RAPPS] Addendum to 0.4.15-dev-3724-g3a7c0d8 CORE-18018
Joachim Henze [Sun, 23 Jan 2022 20:21:50 +0000 (21:21 +0100)]
[RAPPS] Addendum to 0.4.15-dev-3724-g3a7c0d8 CORE-18018

For a moment I thought this member was obsolete entirely,
and intended to delete it entirely.
(as its size is just ULONG which is too small for big downloads > 4GB size).
It apparently works also without it to display the size,
as we actually use a different member that stores the size as a string.

But there actually still *is* a usage for that ULONG representation.
In (the rare) corner-case the http download does not allow to query the size,
then the ULONG representation m_SizeBytes is used as a fallback for the
download-progress-bar to avoid 'marquee mode'.

The 'fallback of the fallback' so to say.
We should enlarge this to be a 64bit unsigned value some day.

2 years ago[RAPPS] Fallback to legacy "size" entry is not longer needed CORE-18018
Joachim Henze [Sun, 23 Jan 2022 19:24:47 +0000 (20:24 +0100)]
[RAPPS] Fallback to legacy "size" entry is not longer needed CORE-18018

on 2021-10-03 Mark Jansen deleted all old size entries from the rapps database via
https://git.reactos.org/?p=rapps-db.git;a=commit;h=551e8cb95716f46e05c3be08996467bd93b1936f
So it makes no sense to keep that fallback-code in RAPPS available.cpp RetrieveSize() func.

2 years ago[NTOS:MM] Implement partial virtual region releases. CORE-17938 4204/head
Thomas Faber [Tue, 28 Dec 2021 01:00:45 +0000 (20:00 -0500)]
[NTOS:MM] Implement partial virtual region releases. CORE-17938

Fixes boot with MS videoprt.sys (and some apitests).

2 years ago[ATL][MSPAINT] Add ATLTRACE and fix assertion failures (#4299)
Katayama Hirofumi MZ [Sat, 22 Jan 2022 15:59:12 +0000 (00:59 +0900)]
[ATL][MSPAINT] Add ATLTRACE and fix assertion failures (#4299)

- Implement ATLTRACE and AtlTrace in atlbase.h.
- Fix assertion failures in mspaint.
CORE-17969, CORE-18012

2 years ago[SFCFILES] Add sfcfiles dll and header file
Eric Kohl [Sat, 22 Jan 2022 12:28:50 +0000 (13:28 +0100)]
[SFCFILES] Add sfcfiles dll and header file

Sfcfiles.dll contains only a short list of protected files (WIP).

2 years ago[CRT] Fix MSVC version of call_handler
Thomas Faber [Mon, 17 Jan 2022 00:48:58 +0000 (19:48 -0500)]
[CRT] Fix MSVC version of call_handler

2 years ago[NTUSER] Improve NtUserGetThreadState (#4300) 3798/head
Katayama Hirofumi MZ [Thu, 20 Jan 2022 02:49:27 +0000 (11:49 +0900)]
[NTUSER] Improve NtUserGetThreadState (#4300)

- Improve enum ThreadStateRoutines.
- Improve NtUserGetThreadState function.
- Improve CLIENTIMC structure.
- Improve imm32 code.
CORE-17732

2 years ago[TRANSLATION] Cumulative update for Russian (ru-RU) translation
Stanislav Motylkov [Tue, 18 Jan 2022 20:42:06 +0000 (23:42 +0300)]
[TRANSLATION] Cumulative update for Russian (ru-RU) translation

[SYSDM] Addendum to 5a2911d7e58b4a49ea2ca8fa.
[SHELL32] Addendum to 16f64a9544bb99cc2ae526a034b0f3e4fd39a292.
[SYSSETUP] Addendum to 556cfbf56f1a57a93f053db3.
[SAMSRV] Addendum to 6f1a57a9.
[BOOTDATA] Addendum to 63cd5d54.
[INF] Addendum to fb500b88.

2 years ago[NTUSER] Initialize correctly CaretWidth value. (#4297) CORE-13984 CORE-14359 CORE...
Julio Carchi [Mon, 17 Jan 2022 23:36:49 +0000 (18:36 -0500)]
[NTUSER] Initialize correctly CaretWidth value. (#4297) CORE-13984 CORE-14359 CORE-16624

Fixes:
CORE-13984 LibreOffice Writer shows no blinking caret
CORE-14359 Apache Open Office 4.1.2 SWriter - no blinking Caret
CORE-16624 KVIRC, no blinking caret in configuration edit controls

2 years ago[SHELL32] List CD-ROM drives in the "Hardware" tab of disk properties
Stanislav Motylkov [Mon, 17 Jan 2022 18:04:04 +0000 (21:04 +0300)]
[SHELL32] List CD-ROM drives in the "Hardware" tab of disk properties

CORE-17397

2 years ago[SAMSRV] Fix typo in IDS_ALIAS_BACKUP_OPS_COMMENT (en-US and others)
Stanislav Motylkov [Mon, 17 Jan 2022 17:40:31 +0000 (20:40 +0300)]
[SAMSRV] Fix typo in IDS_ALIAS_BACKUP_OPS_COMMENT (en-US and others)

Addendum to f1e768c0.

2 years ago[USETUP] Default to en-US output codepage when initializing the console. Addendum...
Hermès Bélusca-Maïto [Mon, 17 Jan 2022 15:16:10 +0000 (16:16 +0100)]
[USETUP] Default to en-US output codepage when initializing the console. Addendum to commit 9f201d462.

Reported by julenuri.

2 years ago[WIN32KNT_APITEST] Strengthen NtUserGetThreadState testcase (#4291)
Katayama Hirofumi MZ [Mon, 17 Jan 2022 07:01:31 +0000 (16:01 +0900)]
[WIN32KNT_APITEST] Strengthen NtUserGetThreadState testcase (#4291)

Add some paramters to test on. CORE-17732

2 years ago[SVCHOST][SECLOGON][MSWSOCK] Minimal headers cleanup.
Hermès Bélusca-Maïto [Sun, 16 Jan 2022 23:59:25 +0000 (00:59 +0100)]
[SVCHOST][SECLOGON][MSWSOCK] Minimal headers cleanup.

- SVCHOST, SECLOGON: Add missing NTOS_MODE_USER.
- MSWSOCK: Remove some useless windef.h includes.

2 years ago[INF] Fix Mizu theme display problems with CJK font (#4284)
Luo Yufan [Sun, 16 Jan 2022 23:43:15 +0000 (07:43 +0800)]
[INF] Fix Mizu theme display problems with CJK font (#4284)

Add font substitute from "Source Sans Pro" to "Droid Sans Fallback" if the user is CJK.
CORE-17997

2 years ago[SHELL32] Implement Recycler Bin icons (#4221)
Jesús Sanz del Rey [Sun, 16 Jan 2022 23:20:07 +0000 (00:20 +0100)]
[SHELL32] Implement Recycler Bin icons (#4221)

CORE-3938

Icon extraction from the recycle bin was not possible due to the partial absence of IExtractIcon interface support.
Adding it inside the RecycleBinFile's QueryInterface private implementation, and then calling it from CRecycleBin, now allows retrieving and displaying the files' icons.

2 years ago[BOOTDATA] Make Secondary Logon service name and description translatable
Stanislav Motylkov [Sun, 16 Jan 2022 19:46:36 +0000 (22:46 +0300)]
[BOOTDATA] Make Secondary Logon service name and description translatable

Addendum to 43fa9548.

2 years ago[reactos] Add missing prototypes for svchost callbacks
Eric Kohl [Sun, 16 Jan 2022 18:56:28 +0000 (19:56 +0100)]
[reactos] Add missing prototypes for svchost callbacks

Addendum to 43fa9548d32a10967f9d53c73c1d4484c8927ee8

2 years ago[dhcpsvc][srvsvc][wkssvc] Servcies run by svchost must be shared process services
Eric Kohl [Sun, 16 Jan 2022 16:59:41 +0000 (17:59 +0100)]
[dhcpsvc][srvsvc][wkssvc] Servcies run by svchost must be shared process services

2 years ago[NEWDEV] Disable NewFolder btn and Show browser title when selecting a directory...
Jose Carlos Jesus [Sun, 16 Jan 2022 16:34:59 +0000 (16:34 +0000)]
[NEWDEV] Disable NewFolder btn and Show browser title when selecting a directory (#4288)

* [NEWDEV] Add browser title to rc files

* [NEWDEV] Show browser title when selecting a directory

* Update dll/win32/newdev/lang/pl-PL.rc

Co-authored-by: Adam Stachowicz <saibamenppl@gmail.com>
* Update dll/win32/newdev/lang/bg-BG.rc

Co-authored-by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
* Update dll/win32/newdev/wizard.c

Co-authored-by: Stanislav Motylkov <x86corez@gmail.com>
* Update dll/win32/newdev/lang/pl-PL.rc

Co-authored-by: Adam Stachowicz <saibamenppl@gmail.com>
* Update dll/win32/newdev/lang/pt-PT.rc

Co-authored-by: Stanislav Motylkov <x86corez@gmail.com>
* Remove obvious comment

* Add de-DE and ru-RU translations

* Add French translation

Co-authored-by: Adam Stachowicz <saibamenppl@gmail.com>
Co-authored-by: Hermès BÉLUSCA - MAÏTO <hermes.belusca-maito@reactos.org>
Co-authored-by: Stanislav Motylkov <x86corez@gmail.com>
2 years ago[services] Add the secondary logon service
Eric Kohl [Sun, 16 Jan 2022 16:02:01 +0000 (17:02 +0100)]
[services] Add the secondary logon service

2 years ago[IDL] Add idl file for the secondary logon service
Eric Kohl [Sun, 16 Jan 2022 13:27:13 +0000 (14:27 +0100)]
[IDL] Add idl file for the secondary logon service

2 years ago[SYSDM] Update pl translation (#4289)
Adam Stachowicz [Sun, 16 Jan 2022 12:58:41 +0000 (12:58 +0000)]
[SYSDM] Update pl translation (#4289)

Addendum to https://github.com/reactos/reactos/commit/ecfd01eefc430876a95cbaca595d2f2e6f52a215 and other

2 years ago[SYSDM] pt-PT.rc Fix compiler warning RC4206 CORE-17827
Joachim Henze [Sun, 16 Jan 2022 11:06:26 +0000 (12:06 +0100)]
[SYSDM] pt-PT.rc Fix compiler warning RC4206 CORE-17827

Thanks to Twitter user @denzilferreira for that shortened string.

2 years ago[SYSDM] sq-AL.rc Fix compiler warning RC4206 CORE-17827
Joachim Henze [Sun, 16 Jan 2022 09:13:40 +0000 (10:13 +0100)]
[SYSDM] sq-AL.rc Fix compiler warning RC4206 CORE-17827

Thanks to Twitter users @illyrian598 and @jan_shkreli for that shortened string.

2 years ago[SYSDM] sk-SK.rc Fix compiler warning RC4206 CORE-17827
Joachim Henze [Sun, 16 Jan 2022 07:09:14 +0000 (08:09 +0100)]
[SYSDM] sk-SK.rc Fix compiler warning RC4206 CORE-17827

Vic Marcal reached out for help on Twitter for that shortened string.

2 years ago[SYSDM] el-GR.rc Fix compiler warning RC4206
Joachim Henze [Sun, 16 Jan 2022 07:03:28 +0000 (08:03 +0100)]
[SYSDM] el-GR.rc Fix compiler warning RC4206

Vic Marcal reached out for help on Twitter
for that shortened string.

2 years ago[NTUSER] Implement NtUserBuildHimcList (#4286)
Katayama Hirofumi MZ [Sun, 16 Jan 2022 00:56:18 +0000 (09:56 +0900)]
[NTUSER] Implement NtUserBuildHimcList (#4286)

- Add UserBuildHimcList helper function.
- Implement NtUserBuildHimcList function.
CORE-11700

2 years ago[USER32] Adjust the threshold in CascadeWindows (#4283)
Katayama Hirofumi MZ [Sun, 16 Jan 2022 00:54:44 +0000 (09:54 +0900)]
[USER32] Adjust the threshold in CascadeWindows (#4283)

Improve the threshold of CascadeWindows function not to make the windows too small.

2 years ago[PSDK] Add prototypes CreateProcessWithLogonW and CreateProcessWithTokenW
Eric Kohl [Sat, 15 Jan 2022 17:23:59 +0000 (18:23 +0100)]
[PSDK] Add prototypes CreateProcessWithLogonW and CreateProcessWithTokenW

2 years ago[CONSRV] Trivially implement TuiSetCodePage(). CORE-17601
Hermès Bélusca-Maïto [Sat, 3 Jul 2021 22:51:49 +0000 (00:51 +0200)]
[CONSRV] Trivially implement TuiSetCodePage(). CORE-17601

2 years ago[BLUE][CONSRV][USETUP] Completely remove support for CAB font extraction from driver...
Hermès Bélusca-Maïto [Sat, 3 Jul 2021 23:46:52 +0000 (01:46 +0200)]
[BLUE][CONSRV][USETUP] Completely remove support for CAB font extraction from driver, and move it to CONSRV, much like what was done for USETUP.

Addendum to aaa416d3 and 2391e31c.

2 years ago[CONSRV] Stub out support for terminal-level changing of output code page.
Hermès Bélusca-Maïto [Sat, 3 Jul 2021 22:41:33 +0000 (00:41 +0200)]
[CONSRV] Stub out support for terminal-level changing of output code page.
CORE-17601

2 years ago[W32TIME] Add Russian (ru-RU) translation (#4287)
Nikki Next [Sat, 15 Jan 2022 11:32:25 +0000 (16:32 +0500)]
[W32TIME] Add Russian (ru-RU) translation (#4287)

Addendum to 3d8d88ea.

2 years ago[SYSDM] Add missing changes from e58b4a49 to zh-HK resource file
Stanislav Motylkov [Sat, 15 Jan 2022 00:18:10 +0000 (03:18 +0300)]
[SYSDM] Add missing changes from e58b4a49 to zh-HK resource file

2 years ago[SYSDM] Add mnemonic/access keys for environment variable editor
Stanislav Motylkov [Fri, 14 Jan 2022 23:48:56 +0000 (02:48 +0300)]
[SYSDM] Add mnemonic/access keys for environment variable editor

Addendum to e58b4a49. CORE-11733

2 years ago[SYSDM] Make file browse filter string translatable
Stanislav Motylkov [Fri, 14 Jan 2022 23:18:04 +0000 (02:18 +0300)]
[SYSDM] Make file browse filter string translatable

Addendum to e58b4a49. CORE-11733

2 years ago[NTDLL:LDR] Don't hardcode process-execute flag values. (#4111) 4111/head
Hermès Bélusca-Maïto [Mon, 15 Nov 2021 23:34:39 +0000 (00:34 +0100)]
[NTDLL:LDR] Don't hardcode process-execute flag values. (#4111)

2 years ago[SDK:NDK] Add the NX_SUPPORT_* flags for the SharedUserData.NXSupportPolicy member...
Hermès Bélusca-Maïto [Mon, 10 Jan 2022 23:11:37 +0000 (00:11 +0100)]
[SDK:NDK] Add the NX_SUPPORT_* flags for the SharedUserData.NXSupportPolicy member. (#4111)

And move those in the XDK to a better place, adding versioning as well.

2 years ago[TRANSLATION] Update Portuguese (pt-PT) translation (#4273)
Jose Carlos Jesus [Fri, 14 Jan 2022 21:40:41 +0000 (21:40 +0000)]
[TRANSLATION] Update Portuguese (pt-PT) translation (#4273)

- [DEVMGR] Improve pt-PT translation
- [NEWDEV] Small improvements to pt-PT translation
- [SHELL32] Update pt-PT translation

2 years ago[TRANSLATION] Update Chinese Traditional (zh-TW) translation (#4154)
Chan Chilung [Fri, 14 Jan 2022 17:22:46 +0000 (01:22 +0800)]
[TRANSLATION] Update Chinese Traditional (zh-TW) translation (#4154)

- Added translation for:
  - [W32TIME]
  - [MODE]
  - [TIMEOUT]
  - [MODEMUI]
  - [ARPING]
  - [FRAGINATOR]
  - and more
- Updated existing translation
- [WINNLS] Update cht (zh-TW) and zhh (zh-HK)
- [DOC] Update rules in Chinese translation notes.txt
- Wine translation sync

Some of the punctuation use in WIne has been converted to half-width,
so the punctuation will no longer synced.

2 years ago[MSGINA] Adjust Status Window if Asian
Katayama Hirofumi MZ [Fri, 14 Jan 2022 03:44:29 +0000 (12:44 +0900)]
[MSGINA] Adjust Status Window if Asian

The Asian logo and bar positions are different from English or Latin positions, due to Asian font.
Add positional adjustment to IDD_STATUS if Asian.
Follow-up of #4280 ef4f0d0.

2 years ago[SYSSETUP] Adjust Status Window if Asian (#4280)
Katayama Hirofumi MZ [Fri, 14 Jan 2022 02:39:24 +0000 (11:39 +0900)]
[SYSSETUP] Adjust Status Window if Asian (#4280)

The Asian logo and bar positions are different from English or Latin positions, due to Asian font.
Add positional adjustment to IDD_STATUSWINDOW_DLG if Asian.

2 years ago[TRANSLATION] Update Simplified Chinese (zh-CN) translation (#4240)
Luo Yufan [Thu, 13 Jan 2022 21:00:37 +0000 (05:00 +0800)]
[TRANSLATION] Update Simplified Chinese (zh-CN) translation (#4240)

Reviewed-by: Chan Chilung <eason066@gmail.com>
Reviewed-by: He Yang <1160386205@qq.com>
2 years ago[NET] Improve displaying status message (#4096)
Marat Nagayev [Thu, 13 Jan 2022 15:10:55 +0000 (15:10 +0000)]
[NET] Improve displaying status message (#4096)

- Simplify conditions
- Add application error translation function

[NET][MC] Add missing Russian (ru-RU) translation

2 years ago[SAMSRV] Return correct status for existing groups and users 4282/head
Stanislav Motylkov [Thu, 13 Jan 2022 13:38:04 +0000 (16:38 +0300)]
[SAMSRV] Return correct status for existing groups and users

[NETAPI32] NetpNtStatusToApiStatus: Update accordingly

This fixes net command output in PR #4096.

2 years ago[USERSRV][TRANSLATION] Improve Japanese (ja-JP.rc)
Katayama Hirofumi MZ [Thu, 13 Jan 2022 05:09:03 +0000 (14:09 +0900)]
[USERSRV][TRANSLATION] Improve Japanese (ja-JP.rc)

2 years ago[POWERCFG][TRANSLATION] Improve Japanese (ja-JP.rc)
Katayama Hirofumi MZ [Thu, 13 Jan 2022 02:44:02 +0000 (11:44 +0900)]
[POWERCFG][TRANSLATION] Improve Japanese (ja-JP.rc)

2 years ago[WINLOGON][TRANSLATION] Improve Japanese translation (ja-JP.rc)
Katayama Hirofumi MZ [Thu, 13 Jan 2022 02:40:05 +0000 (11:40 +0900)]
[WINLOGON][TRANSLATION] Improve Japanese translation (ja-JP.rc)

2 years ago[NTUSER] Follow-up of #4277 (ea1353e)
Katayama Hirofumi MZ [Thu, 13 Jan 2022 01:41:03 +0000 (10:41 +0900)]
[NTUSER] Follow-up of #4277 (ea1353e)

According to ThFabba, NtUserSetThreadLayoutHandles returns zero.
CORE-11700

2 years ago[NTUSER] Implement NtUserSetThreadLayoutHandles (#4277)
Katayama Hirofumi MZ [Wed, 12 Jan 2022 05:48:20 +0000 (14:48 +0900)]
[NTUSER] Implement NtUserSetThreadLayoutHandles (#4277)

- Modify NtUserSetThreadLayoutHandles prototype.
- Implement NtUserSetThreadLayoutHandles function.
CORE-11700

2 years ago[NTUSER] Follow-up of #4271 (36740ca)
Katayama Hirofumi MZ [Wed, 12 Jan 2022 05:08:10 +0000 (14:08 +0900)]
[NTUSER] Follow-up of #4271 (36740ca)

- Delete the excessive comments.
- Delete the debugging leftover.
CORE-11700

2 years ago[NTUSER] Implement NtUserSetImeInfoEx (#4276)
Katayama Hirofumi MZ [Wed, 12 Jan 2022 03:07:31 +0000 (12:07 +0900)]
[NTUSER] Implement NtUserSetImeInfoEx (#4276)

- Modify NtUserSetImeInfoEx prototype.
- Add UserSetImeInfoEx helper function.
- Implement NtUserSetImeInfoEx function.
CORE-11700

2 years ago[NTUSER][IMM32] Implement NtUserGetImeInfoEx (#4271)
Katayama Hirofumi MZ [Wed, 12 Jan 2022 03:06:24 +0000 (12:06 +0900)]
[NTUSER][IMM32] Implement NtUserGetImeInfoEx (#4271)

- Add UserGetImeInfoEx helper function.
- Implement NtUserGetImeInfoEx function by using UserGetImeInfoEx.
- Fix imm32.ImmGetImeInfoEx.
- Modify enum IMEINFOEXCLASS.
CORE-11700

2 years ago[USER32] Improve icon extraction to handle RIFF formats and Fix crash (#4262)
Doug Lyons [Tue, 11 Jan 2022 23:03:44 +0000 (17:03 -0600)]
[USER32] Improve icon extraction to handle RIFF formats and Fix crash (#4262)

- Add handling for 'RIFF' formats (for animated cursors). This makes explorer able to display animated cursors.
- Fix crash in extracting icons/cursors.
CORE-16287

2 years ago[DESK] Update available settings when selecting another display
Hervé Poussineau [Tue, 11 Jan 2022 17:05:36 +0000 (18:05 +0100)]
[DESK] Update available settings when selecting another display

2 years ago[DESK] Factorize changing device description to OnDisplayDeviceChanged()
Hervé Poussineau [Tue, 11 Jan 2022 17:05:04 +0000 (18:05 +0100)]
[DESK] Factorize changing device description to OnDisplayDeviceChanged()

2 years ago[SHELL32:WINE][PSDK] Addendum to 0bf768a1: Add missing FARPROC16 definition for CallC...
Hermès Bélusca-Maïto [Tue, 11 Jan 2022 22:31:26 +0000 (23:31 +0100)]
[SHELL32:WINE][PSDK] Addendum to 0bf768a1: Add missing FARPROC16 definition for CallCPLEntry16() prototype.

2 years ago[SHELL32:WINE][PSDK] Fix the prototype of CallCPLEntry16().
Hermès Bélusca-Maïto [Mon, 10 Jan 2022 19:07:49 +0000 (20:07 +0100)]
[SHELL32:WINE][PSDK] Fix the prototype of CallCPLEntry16().

2 years ago[KERNEL32] Add missing NTOS_MODE_USER when including the NDK.
Hermès Bélusca-Maïto [Tue, 11 Jan 2022 21:44:03 +0000 (22:44 +0100)]
[KERNEL32] Add missing NTOS_MODE_USER when including the NDK.

2 years ago[CPORTLIB] Remove any usage of debug.h since this lib implements the support for...
Hermès Bélusca-Maïto [Tue, 11 Jan 2022 21:41:52 +0000 (22:41 +0100)]
[CPORTLIB] Remove any usage of debug.h since this lib implements the support for said debugging output.

2 years ago[CRT/arm64] Fix handling of intrinsics
Serge Gautherie [Mon, 24 May 2021 06:56:17 +0000 (08:56 +0200)]
[CRT/arm64] Fix handling of intrinsics

Fix msvc14.1-arm64-Release build.

Follow-up to db41787 (0.4.15-dev-2914).
CORE-17518

2 years ago[CRT/arm64] Build wine/except_arm64.c
Serge Gautherie [Mon, 24 May 2021 06:56:17 +0000 (08:56 +0200)]
[CRT/arm64] Build wine/except_arm64.c

Follow-up to 9efafd6 (0.4.14-dev-934).
CORE-17518

2 years ago[BCRYPT] Add ECDSA P384 to known algorithms
Serge Gautherie [Thu, 12 Nov 2020 00:22:46 +0000 (01:22 +0100)]
[BCRYPT] Add ECDSA P384 to known algorithms

Add missing structs and handler in BCryptOpenAlgorithmProvider().

Cherry-pick a part of Michael Müller's
https://source.winehq.org/git/wine.git/commit/76b6c360fa7f3d6a0a14ed935075f5eb10f2f719

Follow-up to e0a47b7 (0.4.15-dev-3603).
CORE-14198

2 years ago[NTOS:PS] Use quota types on process quota querying
George Bișoc [Tue, 11 Jan 2022 10:21:15 +0000 (11:21 +0100)]
[NTOS:PS] Use quota types on process quota querying

Quota limits on a block are enumerated on a per quota type basis thus we should use the values from PS_QUOTA_TYPE enumeration, not from POOL_TYPE.

2 years ago[KMTESTS:PS] Write some tests for process quota management 4184/head
George Bișoc [Thu, 30 Dec 2021 20:06:03 +0000 (21:06 +0100)]
[KMTESTS:PS] Write some tests for process quota management

2 years ago[NTOS:OB] Charge/Return pool quotas of objects
George Bișoc [Thu, 30 Dec 2021 20:04:42 +0000 (21:04 +0100)]
[NTOS:OB] Charge/Return pool quotas of objects

As it currently stands the Object Manager doesn't charge any quotas when objects are created, nor it returns quotas when objects are de-allocated and freed from the objects namespace database. This alone can bring inconsistencies in the kernel as we simply don't know what is the amount charged in an object and thus we aren't keeping track of quotas flow.

Now with both PsReturnSharedPoolQuota and PsChargeSharedPoolQuota implemented, the Object Manager can now track the said flow of quotas every time an object is created or de-allocated, thus enforcing consistency with the use of quota resources.

2 years ago[NTOS:PS] Dereference the quota block during process cleanup
George Bișoc [Thu, 30 Dec 2021 20:03:42 +0000 (21:03 +0100)]
[NTOS:PS] Dereference the quota block during process cleanup

Ensure that when we're cleaning up the EPROCESS object, that we are dereferencing the quota block the process in question was using. The routine will automatically request a quota block cleanup if the process that dereferenced the quota block was the last.

2 years ago[NTOS:PS] Process Quota Overhaul
George Bișoc [Thu, 30 Dec 2021 20:02:51 +0000 (21:02 +0100)]
[NTOS:PS] Process Quota Overhaul

-- Rewrite PspChargeProcessQuotaSpecifiedPool and PspReturnProcessQuotaSpecifiedPool private kernel routines, with the goal to implement the algorithms necessary to manage the fields of quota blocks (Usage, Return, Limit and Peak).
-- Invoke the Mm if quota limit raising or returning has to be done
-- When destroying a quota block, make sure that we're giving back all the rest of non-returned quotas to Memory Mm
-- Crash the system with QUOTA_UNDERFLOW if someone is returning way too much quota than it was previously charged
-- When a process exits, ensure that it doesn't hold up any charged quotas in QuotaUsage field of the process object, that way we're enforcing proper kernel consistency
-- Implement PsChargeSharedPoolQuota and PsChargeProcessPageFileQuota functions, used exclusively by the Object Manager. These routines are used to charge or return amount of quotas of a newly created object.
-- On PspInheritQuota, when assigning to process the default quota block if no parent process is given, we must increment the reference counts as we're using it
-- Handle the ProcessCount reference field, as it wasn't used
-- Annotate the functions with SAL
-- Document the code

=== REMARKS ===
Windows LogOn (Winlogon) is responsible for setting up a different quota block for all the processes within an interactive session, which is what we don't do. What we're currently doing instead is we're using the default block, PspDefaultQuotaBlock, for all the processes
across the system. The default block contains the default limits of -1 (which would imply no limits). By definition, the kernel won't ever return STATUS_QUOTA_EXCEEDED as we literally don't set up a definite limit for regular processes. This situation has to be tackled
in the future.

=== TODO FOR FUTURE ===
Most of the code in PspChargeProcessQuotaSpecifiedPool and PspReturnProcessQuotaSpecifiedPool private routines must be refactored in order to reduce the usage of the quota spin lock, possibly wrapping such code in a loop and whatnot.

CORE-17784

2 years ago[NTOS:MM] Implement Raise/Return pool quota functions
George Bișoc [Thu, 30 Dec 2021 20:00:52 +0000 (21:00 +0100)]
[NTOS:MM] Implement Raise/Return pool quota functions

This implements both MmRaisePoolQuota and MmReturnPoolQuota functions, which serve exclusively for quota pool management. The process manager communicates with the memory manager in a call of need to charge or return pool quota limits.

2 years ago[NTOS:OB] Add a system process quota block macro
George Bișoc [Thu, 30 Dec 2021 19:59:57 +0000 (20:59 +0100)]
[NTOS:OB] Add a system process quota block macro

OBP_SYSTEM_PROCESS_QUOTA is a macro that'll be used as a way to assign a dummy quota block to system processes, as we mustn't do anything to those in case the Object Manager is charging or returning pool quotas.

2 years ago[NTOS:PS] Declare some prototypes and annotate the quota functions with SAL
George Bișoc [Thu, 30 Dec 2021 19:58:37 +0000 (20:58 +0100)]
[NTOS:PS] Declare some prototypes and annotate the quota functions with SAL

Declare PsReturnSharedPoolQuota and PsChargeSharedPoolQuota prototypes and annotate the functions. Furthermore, add two definitions related to quota pool limits threshold -- PSP_NON_PAGED_POOL_QUOTA_THRESHOLD and PSP_PAGED_POOL_QUOTA_THRESHOLD. For further details, see the commit description of "[NTOS:MM] Add the pool quota prototypes and some definitions".

2 years ago[NTOS:MM] Add the pool quota prototypes and some definitions
George Bișoc [Thu, 30 Dec 2021 19:57:14 +0000 (20:57 +0100)]
[NTOS:MM] Add the pool quota prototypes and some definitions

Declare the MmRaisePoolQuota and MmReturnPoolQuota prototypes in the header and add some definitions related to pool quotas, namely MmTotalNonPagedPoolQuota and MmTotalPagedPoolQuota. These variables are used internally by the kernel as sort of "containers" (for the lack of a better term)
which uphold the amount of quotas that the Process Manager is requesting the Memory Manager to raise or return the pool quota limit. In addition to that, add some definitions needed for both of these functions.

The definitions, MI_CHARGE_PAGED_POOL_QUOTA and MI_CHARGE_NON_PAGED_POOL_QUOTA respectively, bear some interesting aspect. Seemingly the 0x80000 and 0x10000 values (that would denote to 524288 and 65536 specifically) are used as quota "limits" or in other words, thresholds that the kernel
uses. So for example if one would want to raise the quota limit charge, MmRaisePoolQuota will raise it so based on this formula -- NewMaxQuota = CurrentQuota + LIMIT_VALUE. LIMIT_VALUE can be either MI_CHARGE_PAGED_POOL_QUOTA or MI_CHARGE_NON_PAGED_POOL_QUOTA, depending a per quota pool basis.

What's more interesting is that these values are pervasive in Process Manager even. This is when quotas are to be returned back and trim the limit of the quota block if needed, the kernel would either take the amount provided by the caller of quotas to return or the threshold (paged or not paged)
if the amount to return exceeds the said threshold in question.

2 years ago[NTOS:FSRTL] Assign the buffer length to ThisBufferLength field
George Bișoc [Sat, 1 Jan 2022 19:23:28 +0000 (20:23 +0100)]
[NTOS:FSRTL] Assign the buffer length to ThisBufferLength field

This fixes an issue where ReactOS would assert on QuotaUsage == 0 as the process was still taking up quotas during a quota block de-reference with root cause of ThisBufferLength member field being 0 which made process quota charging/returning flow unbalanced.
In addition to that, on FsRtlCancelNotify routine API all we must ensure that if PsChargePoolQuota or ExAllocatePoolWithTag function fails we have to handle the raised exceptions accordingly and return the charged quota back (if we actually charged quotas that is). With said, wrap that part of code with SEH.

=== DOCUMENTATION REMARKS ===
The cause of the assert is due to the fact ThisBufferLength was being handled wrongly ever since, until this commit. When FsRtl of the Executive has to filter reported changes (with logic algorithm implemented in FsRtlNotifyFilterReportChange function), the said function will charge the quota of a given process
with an amount that is represented as the buffer length whose size is expressed in bytes. This length buffer is preserved in a local variable called NumberOfBytes, which is initialized from BufferLength member field of notification structure or from the length from stack parameters pointed from an IRP.

As it currently stands, the code is implemented in such a way that FsRtlNotifyFilterReportChange will charge quotas to a process but it doesn't assign the buffer length to ThisBufferLength. On the first glimpse ThisBufferLength and BufferLength are very similar members that serve exact same purpose but in reality there's a subtle distinction between the two.

BufferLength is a member whose length size is given by FSDs (filesystem drivers) during a notification dispatching. Whenever FsRtl receives the notification structure packed with data from the filesystem, the length pointed by BufferLength gets passed to ThisBufferLength and from now on the kernel has to use this member for the whole time of its task to accomplish
whatever request it's been given by the filesystem. In other words, BufferLength is strictly used only to pass length size data to the kernel by initializing ThisBufferLength based on that length and unequivocally the kernel uses this member field. What we're doing is that ThisBufferLength never receives the length from BufferLength therefore whenever FsRtl component
has to return quotas back it'll return an amount of 0 (which means no amount to return) and that's a bug in the kernel.

2 years ago[NTOS:EX] Manage quotas when allocating or freeing pool tables
George Bișoc [Thu, 30 Dec 2021 20:05:27 +0000 (21:05 +0100)]
[NTOS:EX] Manage quotas when allocating or freeing pool tables

This fixes an assertion where QuotaUsage == 0 is actually not 0 when a process is about to be destroyed.

2 years ago[NTOSKRNL] Implement InterlockedExchangeSizeT macro
George Bișoc [Sun, 2 Jan 2022 19:21:22 +0000 (20:21 +0100)]
[NTOSKRNL] Implement InterlockedExchangeSizeT macro

2 years ago[SHELL32] Fix folders on recycle bin and adjust the column size (#4234)
Jesús Sanz del Rey [Mon, 10 Jan 2022 23:40:25 +0000 (00:40 +0100)]
[SHELL32] Fix folders on recycle bin and adjust the column size (#4234)

CORE-11000

- Now, folders can be sent to recycle bin (fixed a bug inside the implementation).
- Adjust column size of the RecycleBin virtual folder in details mode.

2 years ago[SHELL32] Fix recycle bin handle reference leaking (#4222)
Jesús Sanz del Rey [Mon, 10 Jan 2022 23:20:23 +0000 (00:20 +0100)]
[SHELL32] Fix recycle bin handle reference leaking (#4222)

CORE-13730

There was a handle reference leak in the recycler bin and the bin wasn't removing the copied file after restoring it.
Close the handle were the memory leak was and move the file when restoring it.

2 years ago[MSPAINT] Some minor improvements (#4264)
Katayama Hirofumi MZ [Mon, 10 Jan 2022 12:44:13 +0000 (21:44 +0900)]
[MSPAINT] Some minor improvements (#4264)

- Fix Japanese IDS_MINIATURETITLE resource string.
- Fix Japanese IDM_VIEWSHOWMINIATURE menu item text.
- Fix DWORD as COLORREF.
- Improve some OnPaint's.
CORE-17969

2 years ago[MSPAINT] Don't hide selection on zooming (#4266)
Katayama Hirofumi MZ [Mon, 10 Jan 2022 12:41:00 +0000 (21:41 +0900)]
[MSPAINT] Don't hide selection on zooming (#4266)

- Don't hide the selection window on zooming.
- Move the selection window by calling placeSelWin() when zoomed.
CORE-17969

2 years ago[SDK:DDK][NTOS:PNP] Implement PnP arbiters initialization
Vadim Galyant [Mon, 10 Jan 2022 03:35:45 +0000 (06:35 +0300)]
[SDK:DDK][NTOS:PNP] Implement PnP arbiters initialization

2 years ago[MSPAINT] Prepare for debugging (#4257)
Katayama Hirofumi MZ [Sun, 9 Jan 2022 23:50:37 +0000 (08:50 +0900)]
[MSPAINT] Prepare for debugging (#4257)

- Add #include <debug.h> and add link to ntdll.dll for debugging.
- Add CopyDIBImage helper function.
CORE-17969

2 years ago[SHELL32] Use the already existing g_pszShell32 instead of re-defining a new variable...
Hermès Bélusca-Maïto [Sun, 9 Jan 2022 21:44:21 +0000 (22:44 +0100)]
[SHELL32] Use the already existing g_pszShell32 instead of re-defining a new variable holding the very same string.

2 years ago[SHELL32] Use wide char string literals.
Hermès Bélusca-Maïto [Sun, 9 Jan 2022 21:38:31 +0000 (22:38 +0100)]
[SHELL32] Use wide char string literals.

Import parts of Wine commit b215536852dc5a132108db92c90a41c70b738e50
shell32: Use wide char string literals.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2 years ago[SHELL32] recyclebin.h: Correctly balance the INTERFACE defines/undefs.
Hermès Bélusca-Maïto [Sun, 9 Jan 2022 18:00:46 +0000 (19:00 +0100)]
[SHELL32] recyclebin.h: Correctly balance the INTERFACE defines/undefs.

2 years ago[SYSDM] Fix the "fancy" edit Environment dialog box (#4258)
Arnav Bhatt [Sun, 9 Jan 2022 16:55:25 +0000 (22:25 +0530)]
[SYSDM] Fix the "fancy" edit Environment dialog box (#4258)

Fix the issue of the changes of the environment values not being set sometimes through fancy dialog box:
Make sure the environment value buffer is always reallocated before taking the values.