# Receiver not registered: org.fmod.FMOD$PluginBroadcastReceiver

**URL:** <https://qa.fmod.com/t/receiver-not-registered-org-fmod-fmod-pluginbroadcastreceiver/17484>\
**Category:** FMOD Engine\
**Tags:** android\
**Created:** [July 27, 2021, 4:02pm UTC](https://qa.fmod.com/t/receiver-not-registered-org-fmod-fmod-pluginbroadcastreceiver/17484 "2021-07-27T16:02:48Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dmalyugin](https://avatars.discourse-cdn.com/v4/letter/d/e9a140/32.png) [@dmalyugin](https://qa.fmod.com/u/dmalyugin)\
**Post date:** [July 27, 2021, 4:02pm UTC](https://qa.fmod.com/t/receiver-not-registered-org-fmod-fmod-pluginbroadcastreceiver/17484/1 "2021-07-27T16:02:48Z")

</div>

Sometimes android application crashes with the following error:

F java\_vm\_ext.cc:577] JNI DETECTED ERROR IN APPLICATION: JNI GetStaticMethodID called with pending exception java.lang.IllegalArgumentException: Receiver not registered: org.fmod.FMOD$PluginBroadcastReceiver@2ae2bba  
F java\_vm\_ext.cc:577] at android.content.IIntentReceiver android.app.LoadedApk.forgetReceiverDispatcher(android.content.Context, android.content.BroadcastReceiver) (LoadedApk.java:1459)  
F java\_vm\_ext.cc:577] at void android.app.ContextImpl.unregisterReceiver(android.content.BroadcastReceiver) (ContextImpl.java:1642)  
F java\_vm\_ext.cc:577] at void android.content.ContextWrapper.unregisterReceiver(android.content.BroadcastReceiver) (ContextWrapper.java:715)  
F java\_vm\_ext.cc:577] at void android.content.ContextWrapper.unregisterReceiver(android.content.BroadcastReceiver) (ContextWrapper.java:715)  
F java\_vm\_ext.cc:577] at void org.fmod.FMOD.deregisterHeadsetDetection() (FMOD.java:156)  
F java\_vm\_ext.cc:577]  
F java\_vm\_ext.cc:577] in call to GetStaticMethodID

---

<div class="post-metadata">

**Author:** ![tristanjl](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/tristanjl/32/261_2.png) [@tristanjl](https://qa.fmod.com/u/tristanjl)\
**Post date:** [July 28, 2021, 5:51am UTC](https://qa.fmod.com/t/receiver-not-registered-org-fmod-fmod-pluginbroadcastreceiver/17484/2 "2021-07-28T05:51:00Z")

</div>

This is most likely to occur if you call [System::initialize](https://www.fmod.com/resources/documentation-api?version=2.02&page=studio-api-system.html#studio_system_initialize) before org.fmod.FMOD.init

You should be able to solve this by ensuring that org.fmod.FMOD.init happens before system initialize.

---

<div class="post-metadata">

**Author:** ![dmalyugin](https://avatars.discourse-cdn.com/v4/letter/d/e9a140/32.png) [@dmalyugin](https://qa.fmod.com/u/dmalyugin)\
**Post date:** [July 28, 2021, 8:54am UTC](https://qa.fmod.com/t/receiver-not-registered-org-fmod-fmod-pluginbroadcastreceiver/17484/3 "2021-07-28T08:54:47Z")

</div>

> You should be able to solve this by ensuring that org.fmod.FMOD.init happens before system initialize.

Thanks, that helped to fix one of the issues. I have one more bug report when the same issue is happening in Activity.onDestoy():

```auto
_pCoreSystem->mixerSuspend();

...

FMOD.close();

```

---

<div class="post-metadata">

**Author:** ![tristanjl](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/tristanjl/32/261_2.png) [@tristanjl](https://qa.fmod.com/u/tristanjl)\
**Post date:** [July 28, 2021, 9:44am UTC](https://qa.fmod.com/t/receiver-not-registered-org-fmod-fmod-pluginbroadcastreceiver/17484/4 "2021-07-28T09:44:06Z")

</div>

Before Application.onDestroy is called, you will want to call Studio::release followed by org.fmod.FMOD.close
