From 906bb70654d590b4530d5e56e6ef505e97db55ef Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Thu, 28 Jun 2007 14:47:58 +0000 Subject: [PATCH] update git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5483 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/switch_loadable_module.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/switch_loadable_module.c b/src/switch_loadable_module.c index b46a68a1c1..11d69357a0 100644 --- a/src/switch_loadable_module.c +++ b/src/switch_loadable_module.c @@ -1226,6 +1226,8 @@ SWITCH_DECLARE(int) switch_loadable_module_get_codecs_sorted(const switch_codec_ last = name = next = cur = buf; for (;;) { + + if (!next) { break; } @@ -1233,10 +1235,11 @@ SWITCH_DECLARE(int) switch_loadable_module_get_codecs_sorted(const switch_codec_ *p++ = '\0'; } next = p; + if (cur != name) { if (strchr(cur, 'i')) { interval = atoi(cur); - } else if (strchr(cur, 'k' || strchr(cur, 'h'))) { + } else if ((strchr(cur, 'k') || strchr(cur, 'h'))) { rate = atoi(cur); } }