[asterisk-commits] mnicholson: branch group/res_fax r237572 - /team/group/res_fax/res/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Jan 4 15:43:27 CST 2010


Author: mnicholson
Date: Mon Jan  4 15:43:25 2010
New Revision: 237572

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=237572
Log:
Abort fax when t30_call_active() returns false instead of when we enter phase E

Modified:
    team/group/res_fax/res/res_fax_spandsp.c

Modified: team/group/res_fax/res/res_fax_spandsp.c
URL: http://svnview.digium.com/svn/asterisk/team/group/res_fax/res/res_fax_spandsp.c?view=diff&rev=237572&r1=237571&r2=237572
==============================================================================
--- team/group/res_fax/res/res_fax_spandsp.c (original)
+++ team/group/res_fax/res/res_fax_spandsp.c Mon Jan  4 15:43:25 2010
@@ -168,7 +168,7 @@
 
 	now = ast_tvnow();
 
-	while (s->state != AST_FAX_STATE_COMPLETE) {
+	while (t30_call_active(p->t30_state)) {
 		if (p->ist38) {
 			last_frame = now;
 			now = ast_tvnow();
@@ -180,6 +180,8 @@
 		usleep(SPANDSP_FAX_POLL_TIME);
 	}
 
+	s->state = AST_FAX_STATE_COMPLETE;
+
 	return NULL;
 }
 
@@ -231,8 +233,6 @@
 	char headerinfo[T30_MAX_PAGE_HEADER_INFO + 1];
 	const char *c;
 	t30_stats_t stats;
-
-	s->state = AST_FAX_STATE_COMPLETE;
 
 	t30_get_transfer_statistics(t30_state, &stats);
 




More information about the asterisk-commits mailing list