AudioQueue error 561145187

our app meet a wired problem for online version. more and more user get 561145187 when try to call this code:

AudioQueueNewInput(&self->_recordFormat, inputBufferHandler, (__bridge void *)(self), NULL, NULL, 0, &self->_audioQueue)"

I search for several weeks, but nothing help.

we sum up all issues devices, found some similarity:

  • only happens on iPad OS 14.0 +
  • occurred when app started or wake from background (we call the code when app received "UIApplicationDidBecomeActiveNotification")

Any Idea why this happens?