Skip to content

Commit c33d71f

Browse files
committed
[Ref] mpt/textfile/textfile.hpp: Use more preprocessor checks in get_preferred_encoding() when possible.
git-svn-id: https://source.openmpt.org/svn/openmpt/trunk/OpenMPT@24795 56274372-70c3-4bfc-bfc3-4c3a0b034d27
1 parent 940f2f1 commit c33d71f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/mpt/textfile/textfile.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,8 @@ inline encoding get_preferred_encoding() {
111111
#if MPT_OS_WINDOWS
112112
#if defined(UNICODE)
113113
result = encoding{encoding::type::utf16le, encoding::header::bom};
114+
#elif MPT_WINNT_AT_LEAST(MPT_WIN_2000)
115+
result = encoding{encoding::type::utf16le, encoding::header::bom};
114116
#else
115117
if (mpt::osinfo::windows::Version::Current().IsAtLeast(mpt::osinfo::windows::Version::Win2000)) {
116118
result = encoding{encoding::type::utf16le, encoding::header::bom};

0 commit comments

Comments
 (0)