From 4a278c111dc46e9737932094d7a99872ce5d048d Mon Sep 17 00:00:00 2001
From: Anthony Minessale <anthony.minessale@gmail.com>
Date: Mon, 11 Aug 2008 16:11:50 +0000
Subject: [PATCH] extra blank-string protection

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@9237 d0543943-73ff-0310-b7d9-9358b9ac24b2
---
 src/mod/applications/mod_conference/mod_conference.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/src/mod/applications/mod_conference/mod_conference.c b/src/mod/applications/mod_conference/mod_conference.c
index 9071e5d676..82bf9a5da9 100644
--- a/src/mod/applications/mod_conference/mod_conference.c
+++ b/src/mod/applications/mod_conference/mod_conference.c
@@ -2384,7 +2384,9 @@ static switch_status_t conference_member_play_file(conference_member_t *member,
 		expanded = NULL;
 	}
 	if (!strncasecmp(file, "say:", 4)) {
-		status = conference_member_say(member, file + 4, leadin);
+		if (!switch_strlen_zero(file + 4)) {
+			status = conference_member_say(member, file + 4, leadin);
+		}
 		goto done;
 	}
 	if (!switch_is_file_path(file)) {
@@ -2393,7 +2395,7 @@ static switch_status_t conference_member_play_file(conference_member_t *member,
 				goto done;
 			}
 			file = dfile;
-		} else {
+		} else if (!switch_strlen_zero(file)) {
 			status = conference_member_say(member, file, leadin);
 			goto done;
 		}
@@ -2721,7 +2723,7 @@ static switch_status_t conf_api_sub_mute(conference_member_t *member, switch_str
 		return SWITCH_STATUS_GENERR;
 
 	switch_clear_flag_locked(member, MFLAG_CAN_SPEAK);
-	if (member->conference->muted_sound) {
+	if (!switch_strlen_zero(member->conference->muted_sound)) {
 		conference_member_play_file(member, member->conference->muted_sound, 0);
 	} else {
 		char msg[512];
@@ -2753,7 +2755,7 @@ static switch_status_t conf_api_sub_unmute(conference_member_t *member, switch_s
 	if (stream != NULL) {
 		stream->write_function(stream, "OK unmute %u\n", member->id);
 	}
-	if (member->conference->unmuted_sound) {
+	if (!switch_strlen_zero(member->conference->unmuted_sound)) {
 		conference_member_play_file(member, member->conference->unmuted_sound, 0);
 	} else {
 		char msg[512];