diff options
author | Rob Mensching <rob@firegiant.com> | 2022-10-02 19:26:26 -0700 |
---|---|---|
committer | Rob Mensching <rob@firegiant.com> | 2022-10-04 10:44:49 -0700 |
commit | 15e332b88cb473d911cb268580400728014dd01b (patch) | |
tree | a6d366fbddf3685274fd2e6abc9d0566db42b022 /src/libs/dutil/WixToolset.DUtil/verutil.cpp | |
parent | 05f2de99258c81b2781a9dd30847a00242f53180 (diff) | |
download | wix-15e332b88cb473d911cb268580400728014dd01b.tar.gz wix-15e332b88cb473d911cb268580400728014dd01b.tar.bz2 wix-15e332b88cb473d911cb268580400728014dd01b.zip |
Fix verutil string comparisons
Invariant string comparisons were finding strings like "abc" to be
less than "-abc". Switching to ordinal comparison correctly reports
the order.
Diffstat (limited to 'src/libs/dutil/WixToolset.DUtil/verutil.cpp')
-rw-r--r-- | src/libs/dutil/WixToolset.DUtil/verutil.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libs/dutil/WixToolset.DUtil/verutil.cpp b/src/libs/dutil/WixToolset.DUtil/verutil.cpp index 276441b5..e6ef5039 100644 --- a/src/libs/dutil/WixToolset.DUtil/verutil.cpp +++ b/src/libs/dutil/WixToolset.DUtil/verutil.cpp | |||
@@ -660,7 +660,7 @@ static HRESULT CompareVersionSubstring( | |||
660 | HRESULT hr = S_OK; | 660 | HRESULT hr = S_OK; |
661 | int nResult = 0; | 661 | int nResult = 0; |
662 | 662 | ||
663 | nResult = ::CompareStringW(LOCALE_INVARIANT, NORM_IGNORECASE, wzString1, cchCount1, wzString2, cchCount2); | 663 | nResult = ::CompareStringOrdinal(wzString1, cchCount1, wzString2, cchCount2, TRUE); |
664 | if (!nResult) | 664 | if (!nResult) |
665 | { | 665 | { |
666 | VerExitOnLastError(hr, "Failed to compare version substrings"); | 666 | VerExitOnLastError(hr, "Failed to compare version substrings"); |