https://git.reactos.org/?p=reactos.git;a=commitdiff;h=2c9dbacebbee6b53bf331…
commit 2c9dbacebbee6b53bf331e032d9f2af4e4f828eb
Author: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
AuthorDate: Sat Jan 1 02:24:52 2022 +0100
Commit: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
CommitDate: Sat Jan 1 05:04:22 2022 +0100
[FREELDR] Fix displayed information in the Exception BSOD.
CORE-16748
- Display the correct TR register value.
- Ensure that the x86 segment register values displayed are really
2-byte long.
Segment registers are intrinsically 16 bits. Even if the x86
KTRAP_FRAME structure stores them as ULONG, only their lower 16 bits
are initialized. We thus cast them to USHORT before display.
These segment registers are saved in a stack-based KTRAP_FRAME by the
CPU trap mechanism (for SS), and by 'push CS' etc. instructions for
the others, and from Intel documentation, we know that:
"
If the source operand is a segment register (16 bits) and the operand
size is 64-bits, a zero-extended value is pushed on the stack; if the
operand size is 32-bits, either a zero-extended value is pushed on the
stack or the segment selector is written on the stack using a 16-bit
move. For the last case, all recent Core and Atom processors perform
a 16-bit move, leaving the upper portion of the stack location unmodified.
"
So it may happen, when using the push, that either they get zero-extended,
or garbage gets stored in the higher bits, and these need to be trimmed.
---
boot/freeldr/freeldr/arch/i386/i386bug.c | 18 +++++++++++-------
1 file changed, 11 insertions(+), 7 deletions(-)
diff --git a/boot/freeldr/freeldr/arch/i386/i386bug.c b/boot/freeldr/freeldr/arch/i386/i386bug.c
index f94639650f4..908ad46950c 100644
--- a/boot/freeldr/freeldr/arch/i386/i386bug.c
+++ b/boot/freeldr/freeldr/arch/i386/i386bug.c
@@ -140,18 +140,22 @@ i386PrintExceptionText(ULONG TrapIndex, PKTRAP_FRAME TrapFrame, PKSPECIAL_REGIST
TrapFrame->Dr6);
PrintText(" DR7: %.8lx\n\n",
TrapFrame->Dr7);
+
+ /* NOTE: Segment registers are intrinsically 16 bits. Even if the x86
+ * KTRAP_FRAME structure stores them as ULONG, only their lower 16 bits
+ * are initialized. We thus cast them to USHORT before display. */
PrintText("CS: %.4lx EIP: %.8lx\n",
- TrapFrame->SegCs, TrapFrame->Eip);
+ (USHORT)TrapFrame->SegCs, TrapFrame->Eip);
PrintText("DS: %.4lx ERROR CODE: %.8lx\n",
- TrapFrame->SegDs, TrapFrame->ErrCode);
+ (USHORT)TrapFrame->SegDs, TrapFrame->ErrCode);
PrintText("ES: %.4lx EFLAGS: %.8lx\n",
- TrapFrame->SegEs, TrapFrame->EFlags);
+ (USHORT)TrapFrame->SegEs, TrapFrame->EFlags);
PrintText("FS: %.4lx GDTR Base: %.8lx Limit: %.4x\n",
- TrapFrame->SegFs, Special->Gdtr.Base, Special->Gdtr.Limit);
+ (USHORT)TrapFrame->SegFs, Special->Gdtr.Base, Special->Gdtr.Limit);
PrintText("GS: %.4lx IDTR Base: %.8lx Limit: %.4x\n",
- TrapFrame->SegGs, Special->Idtr.Base, Special->Idtr.Limit);
+ (USHORT)TrapFrame->SegGs, Special->Idtr.Base, Special->Idtr.Limit);
PrintText("SS: %.4lx LDTR: %.4lx TR: %.4lx\n\n",
- TrapFrame->HardwareSegSs, Special->Ldtr, Special->Idtr.Limit);
+ (USHORT)TrapFrame->HardwareSegSs, Special->Ldtr, Special->Tr);
i386PrintFrames(TrapFrame); // Display frames
InstructionPointer = (PUCHAR)TrapFrame->Eip;
@@ -176,7 +180,7 @@ i386PrintExceptionText(ULONG TrapIndex, PKTRAP_FRAME TrapFrame, PKSPECIAL_REGIST
PrintText("GS: %.4lx IDTR Base: %.8lx Limit: %.4x\n",
TrapFrame->SegGs, Special->Idtr.Base, Special->Idtr.Limit);
PrintText("SS: %.4lx LDTR: %.4lx TR: %.4lx\n\n",
- TrapFrame->SegSs, Special->Ldtr, Special->Idtr.Limit);
+ TrapFrame->SegSs, Special->Ldtr, Special->Tr);
InstructionPointer = (PUCHAR)TrapFrame->Rip;
#endif
PrintText("\nInstruction stream: %.2x %.2x %.2x %.2x %.2x %.2x %.2x %.2x \n",
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=e05010193e01162f0a0fc…
commit e05010193e01162f0a0fcd95ea13bac89fedb76d
Author: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
AuthorDate: Fri Dec 31 17:58:54 2021 +0100
Commit: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
CommitDate: Fri Dec 31 23:55:32 2021 +0100
[MSGINA][SHELL32] Update some resources information.
---
dll/win32/msgina/resources/README.txt | 4 ++--
dll/win32/msgina/resources/svg/reactos.svg | 6 ++----
dll/win32/msgina/resources/svg/rosbanner.svg | 2 +-
dll/win32/shell32/res/bitmaps/Readme.txt | 2 +-
4 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/dll/win32/msgina/resources/README.txt b/dll/win32/msgina/resources/README.txt
index d211058325c..0c8da7d0c36 100644
--- a/dll/win32/msgina/resources/README.txt
+++ b/dll/win32/msgina/resources/README.txt
@@ -4,7 +4,7 @@ dlg_bg.bmp
image_strip.bmp
reactos_flag.bmp
-Its source is available as the following files:
+Their source is available as the following files:
svg/background.svg
svg/flag.svg
@@ -12,4 +12,4 @@ svg/shut_down.svg
svg/sleep_hibernate.svg
svg/reboot.svg
-These files are in the public domain.
\ No newline at end of file
+These files are in the public domain.
diff --git a/dll/win32/msgina/resources/svg/reactos.svg b/dll/win32/msgina/resources/svg/reactos.svg
index b7b16388f2e..55f54057c41 100644
--- a/dll/win32/msgina/resources/svg/reactos.svg
+++ b/dll/win32/msgina/resources/svg/reactos.svg
@@ -1,6 +1,4 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!-- Created with Inkscape (http://www.inkscape.org/) -->
-
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
@@ -17,8 +15,8 @@
inkscape:version="0.48.2 r9819"
sodipodi:docname="reactos.svg"
inkscape:export-filename="reactos.png"
- inkscape:export-xdpi="90"
- inkscape:export-ydpi="90">
+ inkscape:export-xdpi="96"
+ inkscape:export-ydpi="96">
<defs
id="defs4">
<linearGradient
diff --git a/dll/win32/msgina/resources/svg/rosbanner.svg b/dll/win32/msgina/resources/svg/rosbanner.svg
index 0320420388f..3591265e07b 100644
--- a/dll/win32/msgina/resources/svg/rosbanner.svg
+++ b/dll/win32/msgina/resources/svg/rosbanner.svg
@@ -13,7 +13,7 @@
viewBox="0 0 109.27291 19.050001"
version="1.1"
id="svg8"
- inkscape:export-filename=".\reactos.png"
+ inkscape:export-filename="reactos.png"
inkscape:export-xdpi="96"
inkscape:export-ydpi="96"
inkscape:version="1.0.2-2 (e86c870879, 2021-01-15)"
diff --git a/dll/win32/shell32/res/bitmaps/Readme.txt b/dll/win32/shell32/res/bitmaps/Readme.txt
index 4a466bb6c26..41516f01ddb 100644
--- a/dll/win32/shell32/res/bitmaps/Readme.txt
+++ b/dll/win32/shell32/res/bitmaps/Readme.txt
@@ -7,4 +7,4 @@ Its source is available as the following files:
svg/log_off.svg
svg/switch_user.svg
-These files are in the public domain.
\ No newline at end of file
+These files are in the public domain.