fs_encode: check for file.file_interface before closing

This commit is contained in:
Mathieu Rene 2010-10-12 14:23:55 -04:00
parent 19e86f7c24
commit c25476b568
1 changed files with 8 additions and 2 deletions

View File

@ -195,8 +195,14 @@ int main(int argc, char *argv[])
r = 0;
end:
switch_core_file_close(&fh_input);
switch_core_file_close(&fh_output);
if (fh_input.file_interface) {
switch_core_file_close(&fh_input);
}
if (fh_output.file_interface) {
switch_core_file_close(&fh_output);
}
if (pool) {
switch_core_destroy_memory_pool(&pool);