MidiDeviceException: Internal error (IN_GETPROPERTYRESULT_UNKNOWNERROR) when accessing InputDevice.Name #338
-
|
Hey, I'm having a user report the following error from my app: I've tried making sure the Do you know what causes this exception? Could I be using the API incorrectly, or is there a clean way to safely handle or avoid this exception? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
|
Hi Sander, Well, from what I see, the user is on macOS. This error means OSStatus status = GetDevicePropertyValue(inputDeviceInfo->endpointRef, propertyID, value);
if (status != noErr)
{
switch (status)
{
case kMIDIUnknownEndpoint: return IN_GETPROPERTYRESULT_UNKNOWNENDPOINT;
case SMALL_BUFFER_ERROR: return IN_GETPROPERTYRESULT_TOOLONG;
case kMIDIUnknownProperty: return IN_GETPROPERTYRESULT_UNKNOWNPROPERTY;
}
return IN_GETPROPERTYRESULT_UNKNOWNERROR;
}
return IN_GETPROPERTYRESULT_OK;How often this error is reproduced? Always, sometimes, from the start of device usage? As a workaround I can suggest you to store But my answer is something went wrong with the device or the system function of macOS. Unfortunately I don't know full list of error codes that can be returned by |
Beta Was this translation helpful? Give feedback.
-
|
Hey, The user reports the issue as happening sporadically with no discernable pattern. It seems to happen randomly at any given time while their device is connected. Thank you for the info and the suggestion! |
Beta Was this translation helpful? Give feedback.
Hi Sander,
Well, from what I see, the user is on macOS. This error means
GetDevicePropertyValuesystem function has returned code that doesn't indicate success and it's not in the list of errors I know:How often this error is …