Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

OSStatus NSOSStatusErrorDomain

I received the following error when I get the property using

AudioSessionGetProperty(kAudioSessionProperty_CurrentHardwareSampleRate,&size,
                                      &myAudioDescription.mSampleRate)

Error Produced by above statement is

Error Domain=NSOSStatusErrorDomain Code=560557673 "The operation couldn’t be completed. (OSStatus error 560557673.)"

Now, here what does 560557673 mean and where can I find its explanation?

Documentation only provides NSOSStatusErrorDomain as one of the errors.

like image 798
NNikN Avatar asked Aug 22 '12 18:08

NNikN


1 Answers

That code means the property data size was not correct.

OSStatus is a type commonly used for error codes in OS X and iOS. If the magnitude of the code is less than 1 million, then the code is probably listed in MacErrors.h in the CarbonCore framework. Otherwise, it is probably a four-character code listed in the same header as the function which returned it. You can find the header of a function by command-clicking it in Xcode. The codes will most likely be listed near the top, grouped together. To convert the number to a code, use the Calculator app in Developer view to convert it to hexadecimal and convert each byte to a character.

like image 158
ughoavgfhw Avatar answered Nov 05 '22 03:11

ughoavgfhw