summaryrefslogtreecommitdiff
path: root/RtAudio.cpp
diff options
context:
space:
mode:
authorGary Scavone <gary@music.mcgill.ca>2013-04-15 17:56:31 +0000
committerStephen Sinclair <sinclair@music.mcgill.ca>2013-10-11 01:38:32 +0200
commit91b2f327e23d13ffaae84f83c1f672aa55e8a694 (patch)
treea55e50c0f10146585f6685f210ea01c7a9bc8d83 /RtAudio.cpp
parent906e5ba67f7c253655b7f1a29b832bb7852e1126 (diff)
A few more updates, including new ASIO files (GS).
Diffstat (limited to 'RtAudio.cpp')
-rw-r--r--RtAudio.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/RtAudio.cpp b/RtAudio.cpp
index 3563151..4b600bd 100644
--- a/RtAudio.cpp
+++ b/RtAudio.cpp
@@ -10,7 +10,7 @@
RtAudio WWW site: http://www.music.mcgill.ca/~gary/rtaudio/
RtAudio: realtime audio i/o C++ classes
- Copyright (c) 2001-2012 Gary P. Scavone
+ Copyright (c) 2001-2013 Gary P. Scavone
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation files
@@ -4991,8 +4991,8 @@ static std::string convertTChar( LPCTSTR name )
{
#if defined( UNICODE ) || defined( _UNICODE )
int length = WideCharToMultiByte(CP_UTF8, 0, name, -1, NULL, 0, NULL, NULL);
- std::string s( length, 0 );
- length = WideCharToMultiByte(CP_UTF8, 0, name, wcslen(name), &s[0], length, NULL, NULL);
+ std::string s( length-1, '\0' );
+ WideCharToMultiByte(CP_UTF8, 0, name, -1, &s[0], length, NULL, NULL);
#else
std::string s( name );
#endif