
Now you might think this is normal since 12> 5 but the thing is that if I remove the AMD from If I only enable wait(12) instead, then res returns 0 exactly and strerror(errno) is success. If wait(1) is enabled in the dialplan, all works fine and res returns something positive. The most important instruction in the test AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, " testapp - A test application.") Īs you can see in the dialplan, on asterisk 2, there are 2 wait() instructions. static int app_exec(struct ast_channel *chan, void *data) 26.

" It shows you the basic structure to create your own Asterisk applications.\n" 24. static char *descrip = "This is my first application \n" 23. static char *synopsis = "test application." 22.
Visual dialplan for asterisk code#
I am also attaching here the code of the test application "testapp"ġ. In real life, this is not the case but the symptoms of the problem are exactly the same! That's why I have replicated the problem that I am having in a test application "testapp()" and forcibly redirect the dialplan flow into the human context independently of AMD result. In reality, the problem is part of a big solution that I cannot post over here.


The phone is connected to asterisk 1 that is registered on asterisk 2, so when the phone make a call, asterisk 1 is redirected the call to asterisk 2 where the dialplan is executed. I am having a problem when using AMD and I was hoping someone can shed some lights over the issue.
