Browse Source

ASIO: Call convertASIOString() in getLastDriverError()

tags/2021-05-28
ed 6 years ago
parent
commit
6bb7618e1e
1 changed files with 4 additions and 2 deletions
  1. +4
    -2
      modules/juce_audio_devices/native/juce_win32_ASIO.cpp

+ 4
- 2
modules/juce_audio_devices/native/juce_win32_ASIO.cpp View File

@@ -770,7 +770,7 @@ private:
if (CharPointer_UTF8::isValidString (text, length))
return String::fromUTF8 (text, length);
WCHAR wideVersion[64] = {};
WCHAR wideVersion[512] = {};
MultiByteToWideChar (CP_ACP, 0, text, length, wideVersion, numElementsInArray (wideVersion));
return wideVersion;
}
@@ -1113,9 +1113,11 @@ private:
String getLastDriverError() const
{
jassert (asioObject != nullptr);
char buffer[512] = {};
asioObject->getErrorMessage (buffer);
return String (buffer, sizeof (buffer) - 1);
return convertASIOString (buffer, sizeof (buffer));
}
String initDriver()


Loading…
Cancel
Save