提交 721b8506 authored 作者: Michael Jerris's avatar Michael Jerris

check return from unlink.

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@7080 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 c4832b4b
......@@ -903,7 +903,9 @@ record_file:
if ((*message_len = fh.sample_count / read_codec->implementation->actual_samples_per_second) < profile->min_record_len) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Message is less than minimum record length: %d, discarding it.\n",
profile->min_record_len);
unlink(file_path);
if (unlink(file_path) != 0) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "failed to delete file [%s]\n", file_path);
}
goto record_file;
} else {
status = SWITCH_STATUS_SUCCESS;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论