]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
mod_hash: use esl_recv_timed with a 5000ms timeout when doing api commands
authorMathieu Rene <mrene@avgs.ca>
Tue, 20 Jul 2010 20:24:30 +0000 (16:24 -0400)
committerMathieu Rene <mrene@avgs.ca>
Tue, 20 Jul 2010 20:24:50 +0000 (16:24 -0400)
src/mod/applications/mod_hash/mod_hash.c

index 9ccfaf800ab348ad36cbc7ad474c36966418a3f3..f4eec4f3c161ac4a24b7af11625552bd779dfc72 100644 (file)
@@ -750,7 +750,7 @@ static void *SWITCH_THREAD_FUNC limit_remote_thread(switch_thread_t *thread, voi
                                remote->state = REMOTE_UP;
                        }
                } else {
-                       if (esl_send_recv(&remote->handle, "api hash_dump limit") != ESL_SUCCESS) {
+                       if (esl_send_recv_timed(&remote->handle, "api hash_dump limit", 5000) != ESL_SUCCESS) {
                                esl_disconnect(&remote->handle);
                                switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Disconnected from remote FreeSWITCH (%s) at %s:%d\n",
                                        remote->name, remote->host, remote->port);