Open MageDelfador opened 2 months ago
Interesting, I do not know how to fix this.
Samsung?
Please try to add this to manifest:
android:foregroundServiceType="camera|microphone"
@iddq that might work. I have added it without being able to test it for now.
So I have two Android 13 devices, Samsung and Xiaomi. I also experience the above problem, but only on Samsung.
https://developer.android.com/about/versions/11/privacy/foreground-services
I tested the latest code and it crashed.
My device is Xiaomi.
I am able to reproduce the error now.
tested on samsung android 13 and it is working now. the microphone access is still working while meshenger is not in foreground.
i can reproduce the crash for Android 14. I think the foreground service type is not accurate. The service is not meant to record audio or to use the camera. That would be the job of the CallAcivity.
Does this error occur during a video call? I only use it with audio. How to reproduce the issue?
Does this error occur during a video call? I only use it with audio. How to reproduce the issue?
Crash on startup, only on Android 14.
The error message clearly states that in addition to the FOREGROUND_SERVICE_MICROPHONE permission, other permissions such as RECORD_AUDIO are also required. At runtime, you need to check for the presence of the RECORD_AUDIO permission and request it from the user if necessary.
hm, I do not have much time atm. to debug this and provide a solution. Let's hope we can get this fixed in the next release.
In Android 14, there is no permission to record audio in the background, and meshenger switching to the background can't record. But the camera can work fine in the background.