Skip to content

Commit

Permalink
fix:录音lua编码死机
Browse files Browse the repository at this point in the history
  • Loading branch information
Dozingfiretruck committed Apr 28, 2024
1 parent 0e32ee6 commit 90ac42c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions components/multimedia/luat_lib_multimedia_audio.c
Expand Up @@ -128,13 +128,13 @@ static void record_encode_amr(uint8_t *data, uint32_t len){
static void record_stop_encode_amr(void){
luat_audio_record_stop(g_s_record.multimedia_id);
luat_audio_pm_request(g_s_record.multimedia_id, LUAT_AUDIO_PM_STANDBY);
if (g_s_record.fd){
#ifdef LUAT_USE_INTER_AMR
luat_audio_inter_amr_coder_deinit(g_s_record.encoder_handler);
luat_audio_inter_amr_coder_deinit(g_s_record.encoder_handler);
#else
Encoder_Interface_exit(g_s_record.encoder_handler);
Encoder_Interface_exit(g_s_record.encoder_handler);
#endif
g_s_record.encoder_handler = NULL;
if (g_s_record.fd){
g_s_record.encoder_handler = NULL;
luat_fs_fclose(g_s_record.fd);
g_s_record.fd = NULL;
}
Expand Down

0 comments on commit 90ac42c

Please sign in to comment.