AUBase::DispatchSetProperty ClassInfo error bug
AUBase::DispatchSetProperty ClassInfo error bug
- Subject: AUBase::DispatchSetProperty ClassInfo error bug
- From: Marc Poirier <email@hidden>
- Date: Mon, 15 Sep 2003 10:26:13 -0500 (CDT)
I just noticed a bug in AUBase::DispatchSetProperty in the AU SDK. When
setting the ClassInfo property, it calls RestoreState but does not catch
the error from RestoreState. So the caller always thinks that the
property setting succeeded, even when it didn't. Currently, the code
does this:
case kAudioUnitProperty_ClassInfo:
require(inDataSize == sizeof(CFPropertyListRef *), InvalidPropertyValue);
require(inScope == kAudioUnitScope_Global, InvalidScope);
RestoreState(*(CFPropertyListRef *)inData);
break;
but it should be this:
case kAudioUnitProperty_ClassInfo:
require(inDataSize == sizeof(CFPropertyListRef *), InvalidPropertyValue);
require(inScope == kAudioUnitScope_Global, InvalidScope);
result = RestoreState(*(CFPropertyListRef *)inData);
break;
I've reported this in RADAR, but figured that I'd also post my findings
here so that other folks can patch their AUBase.cpp
Marc
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.