![]() |
Home page |
Mailing list |
Docs
Asterisk developer's documentation :: Codename Pineapple
agi.h File Reference
Definition in file agi.h.
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.
Data Structures | |
| struct | agi_command |
| struct | agi_state |
Typedefs | |
| typedef agi_state | AGI |
Functions | |
| int | ast_agi_register (agi_command *cmd) |
| void | ast_agi_unregister (agi_command *cmd) |
|
|
|
|
|
Definition at line 1673 of file res_agi.c. References ast_log(), agi_command::cmda, commands, LOG_WARNING, and MAX_COMMANDS. 01674 { 01675 int x; 01676 for (x=0; x<MAX_COMMANDS - 1; x++) { 01677 if (commands[x].cmda[0] == agi->cmda[0]) { 01678 ast_log(LOG_WARNING, "Command already registered!\n"); 01679 return -1; 01680 } 01681 } 01682 for (x=0; x<MAX_COMMANDS - 1; x++) { 01683 if (!commands[x].cmda[0]) { 01684 commands[x] = *agi; 01685 return 0; 01686 } 01687 } 01688 ast_log(LOG_WARNING, "No more room for new commands!\n"); 01689 return -1; 01690 }
|
|
|
Definition at line 1692 of file res_agi.c. References agi_command::cmda, commands, and MAX_COMMANDS. 01693 { 01694 int x; 01695 for (x=0; x<MAX_COMMANDS - 1; x++) { 01696 if (commands[x].cmda[0] == agi->cmda[0]) { 01697 memset(&commands[x], 0, sizeof(agi_command)); 01698 } 01699 } 01700 }
|