Fix AU port-name encoding.
authorRobin Gareus <robin@gareus.org>
Wed, 27 Jan 2016 23:00:47 +0000 (00:00 +0100)
committerRobin Gareus <robin@gareus.org>
Wed, 27 Jan 2016 23:00:47 +0000 (00:00 +0100)
This allows us to revert ec8cf4e4, maybe. After testing if
port-names are still properly displayed.

libs/ardour/audio_unit.cc

index 779bda53487a627836d8ae2335d759deeca41420..6cb5c2abd9ca14ab797f90482b60a669d6294ea8 100644 (file)
@@ -659,9 +659,9 @@ AUPlugin::discover_parameters ()
                        const CAAUParameter* param = param_info.GetParamInfo (d.id);
                        const AudioUnitParameterInfo& info (param->ParamInfo());
 
-                       const int len = CFStringGetLength (param->GetName());;
+                       const int len = CFStringGetLength (param->GetName());
                        char local_buffer[len*2];
-                       Boolean good = CFStringGetCString(param->GetName(),local_buffer,len*2,kCFStringEncodingMacRoman);
+                       Boolean good = CFStringGetCString (param->GetName(), local_buffer ,len*2 , kCFStringEncodingUTF8);
                        if (!good) {
                                d.label = "???";
                        } else {