From 93e3462c853917262bc0915e2440b08db49033eb Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Tue, 16 Aug 2011 15:50:21 -0500 Subject: [PATCH] reset handler field on filehandles so it gets cleared on reuse reported by bevenky on irc --- src/switch_core_file.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/switch_core_file.c b/src/switch_core_file.c index 58b63bdc4b..28f1172ff8 100644 --- a/src/switch_core_file.c +++ b/src/switch_core_file.c @@ -135,10 +135,14 @@ SWITCH_DECLARE(switch_status_t) switch_core_perform_file_open(const char *file, switch_uuid_format(uuid_str, &uuid); fh->spool_path = switch_core_sprintf(fh->memory_pool, "%s%s%s.%s", spool_path, SWITCH_PATH_SEPARATOR, uuid_str, ext); + } else { + fh->spool_path = NULL; } if (rhs) { fh->handler = switch_core_strdup(fh->memory_pool, rhs); + } else { + fh->handler = NULL; } if (channels) {