[asterisk-commits] trunk r18025 - /trunk/apps/app_amd.c
asterisk-commits at lists.digium.com
asterisk-commits at lists.digium.com
Thu Apr 6 13:37:30 MST 2006
Author: bweschke
Date: Thu Apr 6 15:37:29 2006
New Revision: 18025
URL: http://svn.digium.com/view/asterisk?rev=18025&view=rev
Log:
More code optimizations. Thanks kpfleming!
Modified:
trunk/apps/app_amd.c
Modified: trunk/apps/app_amd.c
URL: http://svn.digium.com/view/asterisk/trunk/apps/app_amd.c?rev=18025&r1=18024&r2=18025&view=diff
==============================================================================
--- trunk/apps/app_amd.c (original)
+++ trunk/apps/app_amd.c Thu Apr 6 15:37:29 2006
@@ -207,19 +207,8 @@
while ((ret = ast_waitfor(chan, totalAnalysisTime)))
{
- if (ret < 0) {
- /* No Frame: Called Party Must Have Dropped */
- if (option_verbose > 2)
- ast_verbose(VERBOSE_PREFIX_3 "AMD: HANGUP\n");
- if (option_debug)
- ast_log(LOG_DEBUG, "Got hangup\n");
- strcpy(amdStatus , "HANGUP" );
- strcpy(amdCause , "" );
- break;
- }
- f = ast_read(chan);
- if (!f ) {
- /* No Frame: Called Party Must Have Dropped */
+ if (ret < 0 || !(f = ast_read(chan))) {
+ /* No Frame OR Error on ast_waitfor : Called Party Must Have Dropped */
if (option_verbose > 2)
ast_verbose(VERBOSE_PREFIX_3 "AMD: HANGUP\n");
if (option_debug)
More information about the asterisk-commits
mailing list