[asterisk-commits] branch 1.2 - r7908 /branches/1.2/pbx/pbx_spool.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Mon Jan 9 14:08:25 CST 2006


Author: tilghman
Date: Mon Jan  9 14:08:24 2006
New Revision: 7908

URL: http://svn.digium.com/view/asterisk?rev=7908&view=rev
Log:
Bug 6157 - Memory leak

Modified:
    branches/1.2/pbx/pbx_spool.c

Modified: branches/1.2/pbx/pbx_spool.c
URL: http://svn.digium.com/view/asterisk/branches/1.2/pbx/pbx_spool.c?rev=7908&r1=7907&r2=7908&view=diff
==============================================================================
--- branches/1.2/pbx/pbx_spool.c (original)
+++ branches/1.2/pbx/pbx_spool.c Mon Jan  9 14:08:24 2006
@@ -313,8 +313,10 @@
 #endif
 				fclose(f);
 				if (o->retries <= o->maxretries) {
+					now += o->retrytime;
 					if (o->callingpid && (o->callingpid == ast_mainpid)) {
 						safe_append(o, time(NULL), "DelayedRetry");
+						free_outgoing(o);
 						ast_log(LOG_DEBUG, "Delaying retry since we're currently running '%s'\n", o->fn);
 					} else {
 						/* Increment retries */
@@ -327,7 +329,6 @@
 						safe_append(o, now, "StartRetry");
 						launch_service(o);
 					}
-					now += o->retrytime;
 					return now;
 				} else {
 					ast_log(LOG_EVENT, "Queued call to %s/%s expired without completion after %d attempt%s\n", o->tech, o->dest, o->retries - 1, ((o->retries - 1) != 1) ? "s" : "");



More information about the asterisk-commits mailing list