[asterisk-bugs] [Asterisk 0013251]: endbeforehexten=yes is useless now

Asterisk Bug Tracker noreply at bugs.digium.com
Tue Aug 26 12:33:12 CDT 2008


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=13251 
====================================================================== 
Reported By:                sergee
Assigned To:                murf
====================================================================== 
Project:                    Asterisk
Issue ID:                   13251
Category:                   CDR/General
Reproducibility:            always
Severity:                   major
Priority:                   normal
Status:                     feedback
Asterisk Version:           SVN 
SVN Branch (only for SVN checkouts, not tarball releases): 1.6.0 
SVN Revision (number only!): 135435 
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             2008-08-06 15:10 CDT
Last Modified:              2008-08-26 12:33 CDT
====================================================================== 
Summary:                    endbeforehexten=yes is useless now
Description: 
1. Part of code:

  if (c->cdr && ast_opt_end_cdr_before_h_exten)
	                         ast_cdr_end(c->cdr);

- missing (this is how it was
http://svn.digium.com/view/asterisk/trunk/pbx.c?r1=12896&r2=12895&pathrev=12896)

2. I have very simple scenario SIP/A calls SIP/B they talk 30 seconds,
then call is finished. Even after i call ast_cdr_end(chan->cdr) - manually
from my app,  these fields aren't initialized:

chan->cdr->billsec == 0,
chan->cdr->duration == 0,
chan->cdr->answer.tv_sec == 0,
chan->cdr->end.tv_sec == 0

3. as far as i understand, CDRs are posted now as soon as channels are
unbridged. This behavior breaks billings which make calculations inside 'h'
extensions. It would be nice to post CDRs after no more apps are left in
the 'h' extension or to have an application in the DialPlan, something like
CDRPost().

====================================================================== 

---------------------------------------------------------------------- 
 (0091752) chris-mac (reporter) - 2008-08-26 12:33
 http://bugs.digium.com/view.php?id=13251#c91752 
---------------------------------------------------------------------- 
Just to let you know CDR data in 'h' extension is very important in my dial
plan and I would like to help testing the patch. However when I try to
apply it to 1.6.0 branch (r140157) or 1.6.0-rc3 I am getting the following
errors:

root at dev2:/usr/src/asterisk-1.6.0# patch -p0 < ../h-exten4.diff  
patching file apps/app_dial.c
Hunk http://bugs.digium.com/view.php?id=1 FAILED at 1739.
1 out of 1 hunk FAILED -- saving rejects to file apps/app_dial.c.rej
patching file include/asterisk/channel.h
Hunk http://bugs.digium.com/view.php?id=1 FAILED at 510.
Hunk http://bugs.digium.com/view.php?id=2 FAILED at 524.
2 out of 2 hunks FAILED -- saving rejects to file
include/asterisk/channel.h.rej
patching file main/pbx.c
Hunk http://bugs.digium.com/view.php?id=1 succeeded at 3845 with fuzz 2 (offset
1306 lines).
Hunk http://bugs.digium.com/view.php?id=2 succeeded at 3857 (offset 1303 lines).
can't find file to patch at input line 65
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Index: res/res_features.c
|===================================================================
|--- res/res_features.c	(revision 139779)
|+++ res/res_features.c	(working copy)
--------------------------
File to patch:

Could you please let me know how shall I apply  h-exten4.diff ??
Regards,
Chris 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2008-08-26 12:33 chris-mac      Note Added: 0091752                          
======================================================================




More information about the asterisk-bugs mailing list