summaryrefslogtreecommitdiff
path: root/zen/sys_info.cpp
diff options
context:
space:
mode:
authorB. Stack <bgstack15@gmail.com>2022-11-22 08:54:34 -0500
committerB. Stack <bgstack15@gmail.com>2022-11-22 08:54:34 -0500
commita034cfca98d4408b175938740628a54f57eb7614 (patch)
tree501fd78c6276c0be8be8d2c671a58dd0598060b5 /zen/sys_info.cpp
parentadd upstream 11.27 (diff)
downloadFreeFileSync-a034cfca98d4408b175938740628a54f57eb7614.tar.gz
FreeFileSync-a034cfca98d4408b175938740628a54f57eb7614.tar.bz2
FreeFileSync-a034cfca98d4408b175938740628a54f57eb7614.zip
add upstream 11.2811.28
Diffstat (limited to 'zen/sys_info.cpp')
-rw-r--r--zen/sys_info.cpp39
1 files changed, 35 insertions, 4 deletions
diff --git a/zen/sys_info.cpp b/zen/sys_info.cpp
index 87e07f91..5a044c3a 100644
--- a/zen/sys_info.cpp
+++ b/zen/sys_info.cpp
@@ -131,10 +131,28 @@ ComputerModel zen::getComputerModel() //throw FileError
cm.model = beforeFirst(cm.model, L'\u00ff', IfNotFoundReturn::all); //fix broken BIOS entries:
cm.vendor = beforeFirst(cm.vendor, L'\u00ff', IfNotFoundReturn::all); //0xff can be considered 0
+ trim(cm.model, false, true, [](wchar_t c) { return c == L'_'; }); //e.g. "CBX3___" or just "_"
+ trim(cm.vendor, false, true, [](wchar_t c) { return c == L'_'; }); //e.g. "DELL__" or just "_"
+
for (const char* dummyModel :
{
- "To Be Filled By O.E.M.", "Default string", "$(DEFAULT_STRING)", "Undefined", "empty", "O.E.M", "OEM", "NA",
- "System Product Name", "Please change product name", "INVALID",
+ "Please change product name",
+ "SYSTEM_PRODUCT_NAME",
+ "System Product Name",
+ "To Be Filled By O.E.M.",
+ "Default string",
+ "$(DEFAULT_STRING)",
+ "<null string>",
+ "Product Name",
+ "Undefined",
+ "INVALID",
+ "Unknow",
+ "empty",
+ "O.E.M.",
+ "O.E.M",
+ "OEM",
+ "NA",
+ ".",
})
if (equalAsciiNoCase(cm.model, dummyModel))
{
@@ -144,8 +162,21 @@ ComputerModel zen::getComputerModel() //throw FileError
for (const char* dummyVendor :
{
- "To Be Filled By O.E.M.", "Default string", "$(DEFAULT_STRING)", "Undefined", "empty", "O.E.M", "OEM", "NA",
- "System manufacturer", "OEM Manufacturer",
+ "OEM Manufacturer",
+ "SYSTEM_MANUFACTURER",
+ "System manufacturer",
+ "System Manufacter",
+ "To Be Filled By O.E.M.",
+ "Default string",
+ "$(DEFAULT_STRING)",
+ "Undefined",
+ "Unknow",
+ "empty",
+ "O.E.M.",
+ "O.E.M",
+ "OEM",
+ "NA",
+ ".",
})
if (equalAsciiNoCase(cm.vendor, dummyVendor))
{
bgstack15