提交 08aa721c authored 作者: Mike Jerris's avatar Mike Jerris

FS-9714: [core] switch assert on attempted double close of a file handle

上级 cb382084
...@@ -780,9 +780,8 @@ SWITCH_DECLARE(switch_status_t) switch_core_file_close(switch_file_handle_t *fh) ...@@ -780,9 +780,8 @@ SWITCH_DECLARE(switch_status_t) switch_core_file_close(switch_file_handle_t *fh)
switch_status_t status; switch_status_t status;
switch_assert(fh != NULL); switch_assert(fh != NULL);
switch_assert(fh->file_interface != NULL);
if (!switch_test_flag(fh, SWITCH_FILE_OPEN)) { if (!fh->file_interface || !switch_test_flag(fh, SWITCH_FILE_OPEN)) {
return SWITCH_STATUS_FALSE; return SWITCH_STATUS_FALSE;
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论