[OnePlus 3 ROMs, Kernels, Recoveries, & Other Devel] depii:
Whatsapp voice messages on ear

I have a problem with Whatsapp while hearing voice messages on ear. Often i hear voice messages on ear for privacy reasons. But when i receive a message/mail/something-else while hearing a voice message on ear, the phone plays the notification sound and the voice message loud through speakerphone for 2 seconds.

A friend with a OP3 with Oxygen OS and same Whatsapp Version didn't have this problem. So i think, it must be a Resurrection Remix problem.

Anyone with the same issue here?

Here is some logcat while phone switched to speaker while hearing on ear.

10-17 19:34:54.678 2789 3680 D audio_hw_primary: start_output_stream: enter: stream(0xf667e380)usecase(1: low-latency-playback) devices(0x2)
10-17 19:34:54.679 2789 3680 D audio_hw_primary: select_devices: out_snd_device(2: speaker) in_snd_device(0: )
10-17 19:34:54.679 2789 3680 I msm8974_platform: platform_check_and_set_codec_backend_cfg: Usecase bitwidth 16, samplerate 48000
10-17 19:34:54.679 2789 3680 I msm8974_platform: platform_check_and_set_codec_backend_cfg: new_snd_devices[0] is 2
10-17 19:34:54.679 2789 3680 I msm8974_platform: platform_check_codec_backend_cfg Codec selected backend: 0 current bit width: 16 and sample rate: 48000
10-17 19:34:54.679 2789 3680 D msm8974_platform: platform_check_codec_backend_cfg: resetting sample_rate back to default, backend_idx: 0
10-17 19:34:54.679 2789 3680 I msm8974_platform: platform_check_codec_backend_cfg Codec selected backend: 0 updated bit width: 16 and sample rate: 48000
10-17 19:34:54.679 2789 3680 D audio_hw_primary: check_usecases_codec_backend: Usecase (audio-ull-playback) is active on (handset) - disabling ..
10-17 19:34:54.679 2789 3680 D audio_hw_primary: disable_audio_route: reset and update mixer path: audio-ull-playback
10-17 19:34:54.711 2789 3680 D soundtrigger: audio_extn_sound_trigger_update_stream_status: uc_id 12 of type 0 for Event 2, with Raise=0

10-17 19:34:54.711 2789 3680 D hardware_info: hw_info_append_hw_type : device_name = handset
10-17 19:34:54.711 2789 3680 D audio_hw_primary: disable_snd_device: snd_device(1: handset)
10-17 19:34:54.713 2789 3680 D aud_dev_arbi: releaseOneDevice: not sending command, device argument (1) does not match any registered device
10-17 19:34:54.713 2789 3680 D aud_dev_arbi: releaseOneDevice: device 1 owner is 0
10-17 19:34:54.713 2789 3680 I soundtrigger: audio_extn_sound_trigger_update_device_status: device 0x1 of type 0 for Event 0, with Raise=0
10-17 19:34:54.713 2789 3680 D hardware_info: hw_info_append_hw_type : device_name = speaker
10-17 19:34:54.713 2789 3680 D audio_hw_primary: enable_snd_device: snd_device(2: speaker)

10-17 19:34:54.713 2789 3680 I soundtrigger: audio_extn_sound_trigger_update_device_status: device 0x2 of type 0 for Event 1, with Raise=0
10-17 19:34:54.713 2789 3680 D aud_dev_arbi: acquireOneDevice: device owner for device 2 is 1
10-17 19:34:54.717 2789 3680 D soundtrigger: audio_extn_sound_trigger_update_stream_status: uc_id 12 of type 0 for Event 3, with Raise=0
10-17 19:34:54.717 2789 3680 D ACDB-LOADER: ACDB -> send_audio_cal, acdb_id = 15, path = 0, app id = 0x11131, sample rate = 48000
10-17 19:34:54.717 2789 3680 D ACDB-LOADER: ACDB -> AUDIO_SET_VOL_CAL cal type = 12
10-17 19:34:54.717 2789 3680 D ACDB-LOADER: ACDB -> audstrm_cal->cal_type.cal_data.cal_size = 16
10-17 19:34:54.717 2789 3680 D ACDB-LOADER: ACDB -> GET_AFE_TOPOLOGY_ID for adcd_id 15, Topology Id 1025e
10-17 19:34:54.717 2789 3680 D ACDB-LOADER: ACDB -> send_hw_delay : acdb_id = 15 path = 0
10-17 19:34:54.717 2789 3680 D audio_hw_primary: enable_audio_route: apply mixer and update path: audio-ull-playback quat_i2s
10-17 19:34:54.754 2789 3680 D hardware_info: hw_info_append_hw_type : device_name = speaker
10-17 19:34:54.754 2789 3680 I audio_hw_primary: select_devices Selected apptype: 69937
10-17 19:34:54.754 2789 3680 D soundtrigger: audio_extn_sound_trigger_update_stream_status: uc_id 1 of type 0 for Event 3, with Raise=0
10-17 19:34:54.754 2789 3680 I audio_hw_utils: audio_extn_utils_send_app_type_cfg PLAYBACK app_type 69937, acdb_dev_id 15, sample_rate 48000
10-17 19:34:54.755 2789 3680 D ACDB-LOADER: ACDB -> send_audio_cal, acdb_id = 15, path = 0, app id = 0x11131, sample rate = 48000
10-17 19:34:54.755 2789 3680 D ACDB-LOADER: ACDB -> AUDIO_SET_VOL_CAL cal type = 12
10-17 19:34:54.755 2789 3680 D ACDB-LOADER: ACDB -> audstrm_cal->cal_type.cal_data.cal_size = 16
10-17 19:34:54.755 2789 3680 D ACDB-LOADER: ACDB -> GET_AFE_TOPOLOGY_ID for adcd_id 15, Topology Id 1025e
10-17 19:34:54.755 2789 3680 D ACDB-LOADER: ACDB -> send_hw_delay : acdb_id = 15 path = 0
10-17 19:34:54.755 2789 3680 D audio_hw_primary: enable_audio_route: apply mixer and update path: low-latency-playback quat_i2s
10-17 19:34:54.756 2789 3680 D audio_hw_primary: select_devices: done
10-17 19:34:54.757 2789 3680 D msm8974_platform: platform_set_channel_map mixer_ctl_name:Playback Channel Map15
10-17 19:34:54.757 2789 3680 D msm8974_platform: platform_set_channel_map: set mapping(1 2 0 0 0 0 0 0) for channel:2
10-17 19:34:54.778 2789 3680 D audio_hw_primary: start_output_stream: exit