summaryrefslogtreecommitdiff
path: root/res/res_clialiases.c
AgeCommit message (Collapse)Author
2017-12-22Remove as much trailing whitespace as possible.Sean Bright
Change-Id: I873c1c6d00f447269bd841494459efccdd2c19c0
2017-12-14res_clialiases: Fix completion pass-through.Corey Farrell
Never ignore contents of line when generating completion options. Change-Id: I74389efdfea154019d3b56a9f381610614c044c8
2014-07-25Add module support level to ast_module_info structure. Print it in CLI ↵Mark Michelson
"module show" . ASTERISK-23919 #close Reported by Malcolm Davenport Review: https://reviewboard.asterisk.org/r/3802 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@419592 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2014-02-04res_clialiases: Fix crash when reloading and re-aliasing an alias that is in ↵Joshua Colp
use. The code assumed that unregistering the alias would always succeed while in practice this is not actually true. A common case is the "reload" command itself. If the cli_aliases.conf configuration file was changed and reload executed the command would fail to unregister and ultimately point to freed memory. The reload process now checks whether unregistering succeeded or not and if not the old CLI alias is retained. (closes issue ASTERISK-19773) Reported by: Joel Vandal (closes issue ASTERISK-22757) Reported by: Gareth Blades ........ Merged revisions 407205 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 407210 from http://svn.asterisk.org/svn/asterisk/branches/11 ........ Merged revisions 407213 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@407217 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-13The UUID commit removed changes made in res_clialiases.cMark Michelson
This puts back in the changes that are designed to work around a memory leak fix in the CLI code. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377973 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-11Add UUID support to Asterisk.Mark Michelson
This provides a common API for dealing with unique identifiers. The API provides methods to create, parse, copy, and stringify UUIDs. An accompanying unit test is provided that tests all operations. (closes issue ASTERISK-20726) reported by Matt Jordan Review: https://reviewboard.asterisk.org/r/2217 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377846 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-11Fix crash that can occur if CLI registration fails for an aliased command.Mark Michelson
A recent memory leak fix in main/cli.c causes an ast_cli_entry's command field to be freed and NULLed if ast_cli_register() fails. res_clialiases was ignoring the return value of ast_cli_register() and was then passing the NULL command off to a a hash function. This resulted in a crash. The fix is not to ignore the erroneous return value. If ast_cli_register() fails, then we do not continue trying to process the current alias. ........ Merged revisions 377840 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 377842 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 377843 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377844 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-14Doxygen Updates - Title updateAndrew Latham
Update and extend the configuration_file group and enable linking to the resource. Update title that was left behind many years ago. (issue ASTERISK-20259) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375003 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-01Doxygen CleanupAndrew Latham
Start adding configuration file linking and pages. Add module loading doxygen block. Breaking up commits to keep it easy to track (issue ASTERISK-20259) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374165 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-11-29Allow each logging destination and console to have its own notion of the ↵Tilghman Lesher
verbosity level. Review: https://reviewboard.asterisk.org/r/1599 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@346391 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2011-07-14Merged revisions 328247 via svnmerge from Leif Madsen
https://origsvn.digium.com/svn/asterisk/branches/1.10 ................ r328247 | lmadsen | 2011-07-14 16:25:31 -0400 (Thu, 14 Jul 2011) | 14 lines Merged revisions 328209 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r328209 | lmadsen | 2011-07-14 16:13:06 -0400 (Thu, 14 Jul 2011) | 6 lines Introduce <support_level> tags in MODULEINFO. This change introduces MODULEINFO into many modules in Asterisk in order to show the community support level for those modules. This is used by changes committed to menuselect by Russell Bryant recently (r917 in menuselect). More information about the support level types and what they mean is available on the wiki at https://wiki.asterisk.org/wiki/display/AST/Asterisk+Module+Support+States ........ ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@328259 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-16Include an extra newline after "Aliased CLI command" to get back the prompt.Sean Bright
The other issue mentioned in this bug will be more difficult to resolve since we have no idea (right now) of knowing if the command that is aliased has been installed yet. (issue #16978) Reported by: jw-asterisk Tested by: seanbright git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@252848 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-01-11Pass NULL for the ao2_callback function pointer instead of duplicating cb_true.Sean Bright
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@239114 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-10-06Recorded merge of revisions 222152 via svnmerge from Kevin P. Fleming
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r222152 | kpfleming | 2009-10-05 20:16:36 -0500 (Mon, 05 Oct 2009) | 20 lines Fix ao2_iterator API to hold references to containers being iterated. See Mantis issue for details of what prompted this change. Additional notes: This patch changes the ao2_iterator API in two ways: F_AO2I_DONTLOCK has become an enum instead of a macro, with a name that fits our naming policy; also, it is now necessary to call ao2_iterator_destroy() on any iterator that has been created. Currently this only releases the reference to the container being iterated, but in the future this could also release other resources used by the iterator, if the iterator implementation changes to use additional resources. (closes issue #15987) Reported by: kpfleming Review: https://reviewboard.asterisk.org/r/383/ ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@222176 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-05-06Make the code that prevents an infinite loop from happening into a case ↵Joshua Colp
insensitive check. (thanks eliel) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@192736 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2009-05-06Fix an infinite loop with tab completion of CLI aliases that reference ↵Joshua Colp
themselves. (closes issue #15020) Reported by: junky git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@192700 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-12-13Merge ast_str_opaque branch (discontinue usage of ast_str internals)Tilghman Lesher
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@163991 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-12-10Fix reloads of aliased CLI commands. Due to changes done to turn it into a ↵Joshua Colp
single memory allocation we can't just use the existing CLI alias structure. We have to destroy all existing ones and then create new ones. (closes issue #14054) Reported by: pj git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@162923 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-11-25This is basically a complete rollback of r155401, as it was determined thatSean Bright
it would be best to maintain API compatibility. Instead, this commit introduces ao2_callback_data() which is functionally identical to ao2_callback() except that it allows you to pass arbitrary data to the callback. Reviewed by Mark Michelson via ReviewBoard: http://reviewboard.digium.com/r/64 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@158959 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-11-19Fix checking for CONFIG_STATUS_FILEINVALID so that modules don't crash upon ↵Terry Wilson
trying to parse an invalid config git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@157818 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-11-12- Make alias->real_cmd point to the allocated space outside alias->alias.Eliel C. Sardanons
- Register the aliased cli command (or we will not alias anything). - Use ARRAY_LEN() when possible. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@156355 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-11-12Fix a bug caused by using sizeof(pointer) instead of sizeof(the struct)Russell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@156298 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-11-12This commit does two things:Michiel van Baak
- Add CLI aliases module to asterisk. - Remove all deprecated CLI commands from the code Initial work done by file. Junk-Y and lmadsen did a lot of work and testing to get the list of deprecated commands into the configuration file. Deprecated CLI commands are now handled by this new module, see cli_aliases.conf for more info about that. ok russellb@ via reviewboard (closes issue #13735) Reported by: mvanbaak git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@156120 65c4cc65-6c06-0410-ace0-fbb531ad65f3