[Asterisk-code-review] app_sendmf: New SendMF application (asterisk[master])

George Joseph asteriskteam at digium.com
Wed Aug 4 08:35:20 CDT 2021


Attention is currently required from: N A, Joshua Colp, Sarah Autumn.
George Joseph has posted comments on this change. ( https://gerrit.asterisk.org/c/asterisk/+/16080 )

Change subject: app_sendmf: New SendMF application
......................................................................


Patch Set 3: Code-Review-1

(9 comments)

Patchset:

PS3: 
Some of the code in this module isn't used because you didn't implement the AMI part that was in app_senddtmf.  The extra bits needed to implement the AMI part is trivial so you should do so.


File apps/app_sendmf.c:

https://gerrit.asterisk.org/c/asterisk/+/16080/comment/bfa603dc_010b0084 
PS2, Line 232: 	if (peer && ast_autoservice_start(peer)) {
> To be completely frank, I don't know. I started using app_senddtmf as a base for this and modified it, so I retained the structure of that. I would imagine the rationale would be the same as with DTMF, though I don't know what that would be. Can remove if unneeded.

There'd be a "peer" if the application was called with a channel name.  In this case, chan is the channel to play the tones on and "peer" is "this" channel...the one the app was actually called on.


File apps/app_sendmf.c:

https://gerrit.asterisk.org/c/asterisk/+/16080/comment/b00aef8c_4fcaf9dc 
PS3, Line 131:  ast_
Remove the ast_ since this isn't a public function.
The line should also be wrapped.


https://gerrit.asterisk.org/c/asterisk/+/16080/comment/f4cf5eed_3dd161f5 
PS3, Line 147: ast_senddigit_external_m
Remove the ast_ since this isn't a public function.
The line should also be wrapped.
This function was copied from app_senddtmf but is unused here because you didn't implement the AMI call.


https://gerrit.asterisk.org/c/asterisk/+/16080/comment/db6d1f39_1c29a74f 
PS3, Line 163: tatic int external_sleep(struct ast_channel *chan, int ms)
             : {
             : 	usleep(ms * 1000);
             : 	return 0;
             : }
This function was copied from app_senddtmf but is unused here because you didn't implement the AMI call.


https://gerrit.asterisk.org/c/asterisk/+/16080/comment/ba89977b_66411488 
PS3, Line 169: tatic int mf_stream(struct ast_channel *chan, const char *digits, int between, unsigned int duration, unsigned int durationkp, unsigned int durationst, int is_external)
The line should also be wrapped.


https://gerrit.asterisk.org/c/asterisk/+/16080/comment/4d2865fb_0c88ae47 
PS3, Line 177: if (is_external) {
             : 		my_sleep = external_sleep;
             : 		my_senddigit = ast_senddigit_external_mf;
This was copied from app_senddtmf but is unused here because you didn't implement the AMI call. is_external is always 0.


https://gerrit.asterisk.org/c/asterisk/+/16080/comment/3bd49517_0a46add9 
PS3, Line 207: DTMF
MF


https://gerrit.asterisk.org/c/asterisk/+/16080/comment/a4075034_f440de93 
PS3, Line 228: static int ast_mf_stream(struct ast_channel *chan, struct ast_channel *peer, const char *digits, int between, unsigned int duration, unsigned int durationkp, unsigned int durationst)
Remove the ast_ since this isn't a public function.
The line should also be wrapped.



-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/16080
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Change-Id: I5d89afdbccee3f86cc702ed96d882f3d351327a4
Gerrit-Change-Number: 16080
Gerrit-PatchSet: 3
Gerrit-Owner: N A <mail at interlinked.x10host.com>
Gerrit-Reviewer: Friendly Automation
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Joshua Colp <jcolp at sangoma.com>
Gerrit-CC: Sarah Autumn <sarah at endlesstemple.org>
Gerrit-Attention: N A <mail at interlinked.x10host.com>
Gerrit-Attention: Joshua Colp <jcolp at sangoma.com>
Gerrit-Attention: Sarah Autumn <sarah at endlesstemple.org>
Gerrit-Comment-Date: Wed, 04 Aug 2021 13:35:20 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: N A <mail at interlinked.x10host.com>
Comment-In-Reply-To: Joshua Colp <jcolp at sangoma.com>
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20210804/31d39985/attachment-0001.html>


More information about the asterisk-code-review mailing list