Summary: | ASTERISK-04073: [patch] Commments for channel.c /channel.h | ||
Reporter: | Olle Johansson (oej) | Labels: | |
Date Opened: | 2005-05-04 14:34:00 | Date Closed: | 2008-01-15 15:34:37.000-0600 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Documentation |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ( 0) channeldoc.txt | |
Description: | Adds comments in channel.c and adds some documentation to channel.h Disclaimer on file | ||
Comments: | By: Olle Johansson (oej) 2005-05-04 14:42:04 One routine in channel.c was documented in frame.h. Now moved. By: Mark Spencer (markster) 2005-05-04 14:54:17 Looks fine, need someone to code review and merge. Thanks. By: Kevin P. Fleming (kpfleming) 2005-05-04 15:37:02 This hunk looks to be reverting an earlier fix: @@ -1485,7 +1517,11 @@ ast_log(LOG_WARNING, "Dropping deferred DTMF digits on %s\n", chan->name); f = &null_frame; } else if ((f->frametype == AST_FRAME_CONTROL) && (f->subclass == AST_CONTROL_ANSWER)) { +#ifdef ZAPTEL_OPTIMIZATIONS if (prestate == AST_STATE_UP) { +#else + if (chan->_state == AST_STATE_UP) { +#endif ast_log(LOG_DEBUG, "Dropping duplicate answer!\n"); f = &null_frame; } Also, this one: @@ -2066,8 +2102,13 @@ cut = strchr(name,'-'); if (cut) *cut = 0; - if (!strcmp(name, device)) - return AST_DEVICE_INUSE; + if (!strcmp(name, device)) { + if (chan->_state == AST_STATE_RINGING) { + return AST_DEVICE_RINGING; + } else { + return AST_DEVICE_INUSE; + } + } This is definitely not a 'comments/formatting' fix. This is adding a new field to the channel struct: @@ -262,8 +262,10 @@ char macroexten[AST_MAX_EXTENSION]; /*! Current non-macro priority */ int macropriority; - /*! Current extension number */ + /*! Current extension number E164 */ char exten[AST_MAX_EXTENSION]; + /*! Current alphanumeric extension (utf8) */ + char alphaexten[AST_MAX_EXTENSION]; /* Current extension priority */ int priority; /*! Any/all queued DTMF characters */ By: Olle Johansson (oej) 2005-05-04 16:06:57 I think I updated a new version as you reviewed it. I'll remove the alphaexten though... By: Olle Johansson (oej) 2005-05-04 16:08:40 Hmm. Bugs2 can't accept uploading a new file with the same name. I think we could in the old version. I liked that. By: Olle Johansson (oej) 2005-05-06 14:59:00 Some patches never make it properly... Latest, but maybe not last try. :-) By: Kevin P. Fleming (kpfleming) 2005-05-15 00:43:08 I'm still not thrilled about the AST_DEVICE_RINGING change being bundled into a formatting/comments patch, but it seems to be reasonable and it's not worth requesting another patch. Committed to CVS HEAD, thanks! By: Digium Subversion (svnbot) 2008-01-15 15:34:37.000-0600 Repository: asterisk Revision: 5669 U trunk/channel.c U trunk/include/asterisk/channel.h U trunk/include/asterisk/frame.h ------------------------------------------------------------------------ r5669 | kpfleming | 2008-01-15 15:34:36 -0600 (Tue, 15 Jan 2008) | 2 lines code formatting and comments, plus minor device state fix (bug ASTERISK-4073) ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=5669 |