summaryrefslogtreecommitdiffstats
path: root/lib/command_parse.h
Commit message (Collapse)AuthorAgeFilesLines
* Remove a number of "assigned but unused" warnings and other WIPChris Hall2012-04-101-0/+4
| | | | | | | | | | | | | | -Wunused-but-set-variable throws up a number of errors, this patch removes some of thos in bgpd, lib and zebra. Fix crash in vty when using ">*" /dev/null output pipe. Work in Progress (WIP): 1) adding "Watch-Dog" pthread to keep an eye on all other pthreads and state of mutexes etc. 2) creation of Integrated Configuration in vtysh.
* Tidy up some XMALLOC items that were not being XFREE'd.Chris Hall2012-03-221-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | * bgp_peer_index replace unused bgp_peer_index_reset() by bgp_peer_index_finish() and call same at bgp shut-down. discard unused bgp_peer_index_mutex_free() and replace bgp_peer_index_mutex_init() by bgp_peer_index_init_r(). * lib/command.c and command_parse.c add cmd_parser_finish() to discard store of "words" and arrange to call same in cmd_table_terminate(). * reset vector of files in qps_selection_ream(), so that frees the vector body -- which it should have been doing ! * add mem_mt_show_stderr() for debug (for all the use it may be). * fix qpt_mutex_destroy(), qpt_cond_destroy() and qpt_spin_destroy() so that if fail when !qpthreads_active will log the error (and not crash). Sweeps issues under the carpet, but does not hide same.
* Reviewed and improved vty and (particularly) vtysh.Chris Hall2012-02-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * fix stream_put() to accept NULL src (again). * changed how vty terminal reports time-out and end-of-file, and made --more-- show the same as ordinary cli. * tighten on or two stream functions, to cope if for some reason the getp > endp or endp > size. * update documentation in vio_lines.c * fixed (potential) bug which would have tripped up --more-- if were to be required while outputting notification for a cancel operation. * as a new command loop is set up, make sure all start in vst_cmd_running_executing, so that output will be dispatched. * fix uty_std_out_push() and uty_vtysh_out_push to take notice of vst_cmd_running and vst_cmd_executing and change to vst_cmd_complete as required. * fix handling of hold_mark in VOUT_TERM obuf an line control. * fix various state related issues for vtysh server and the vtysh itself. * when vtysh connects to a daemon, the daemon responds with its name and version number. TBD: the vtysh to check that version is as expected ! * clarified handling of errors in vtysh... distinguishing errors reported by the client daemon, and errors in the mechanics of talking to the client daemon. ~
* vtysh partly restored. bgpd not crashing on over-size messages.Chris Hall2012-02-191-124/+69
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | NB: this is a partial interim version -- NOT for production. Reinstate vtysh. In bgpd: cope better with generating oversize messages. The "pipework" branch is no more. There is now "euro_ix" and "euro_ix_b", where 'b' stands for 'bleedin'. The "pipework" is currently in 'bleedin'. Version updated to: 0.99.18ex20b Major changes in this commit: * modified bgpd to avoid crashing if an oversize message is created. At present, any oversize messages are simply discarded. This may be a mistake... since it is possible that some routes that should have been withdrawn are not. TBA. The stream lib facilities have been overhauled to may this easier. * restoring vtysh. At present the vtysh is thought to work, except that it does not currently create integrated configuration files. For the time being, *only* the following compile: lib, bgpd, zebra, vtysh, tests All other daemons will fail to compile, and must be disabled.
* Further improvements to "pipework".ex19pChris Hall2011-09-061-11/+16
| | | | | | | | | | | | | Version advanced to 0.99.18ex19p. Fixed occasional failure to immediately display prompt after previous command output was abandonned by ^C, particularly with "--more--". Completely removed the "~" temporary prompt, and simplified some logic. Added indication of pthread running to "show version".
* Changed gcc options to -std=c99 and -O2, and tighted warnings.Chris Hall2011-09-021-4/+4
| | | | Some small changes to accomodate same.
* Update pipework and improve memory reporting.Chris Hall2011-07-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Improve error handling for all new pipework inputs and outputs. Change behaviour of ^C from VTY Terminal, so that will interrupt output and terminate all running pipes -- including running shell commands. In pipe commands, recognise "~/..." and "~user/..." home directory forms. Changed "~/" to mean the usual home for the current user. "~~/" now means the configuration file directory. Introduced "shdir DIR" command to show what is (currently) what. Changed "<|" so that if the command has a path, it is expanded using Quagga's rules (including "~~/" and "~./") and the "here" directory is set to that path. Fixed collection of stderr output from all pipes so that is separate from stdout output, and is always sent to the base output (eg VTY Terminal). Increase amount of information about the heap that "show mem" shows -- particularly if the "memory_tracker" is enabled. Tested and applied resulting fixes.
* Small improvements to speed of reading of configuration file.Chris Hall2011-03-311-6/+32
| | | | | Tidy up signalling of "ready" to command loop, and checking of appropriate state to close written configuration file.
* Bring "ex" version up to date with 0.99.18ex15pChris Hall2011-03-291-1/+0
| | | | | | | | | Release: 0.99.18ex15p -- Pipework Branch Also fixes issue with unknown attributes -- does not release them prematurely. Contains the "bgpd: New show commands for improved view and address family support", which is post 0.99.18. (But not RFC 5082 GTSM.)
* Upgrade of "pipework" -- including piping to/from shell commandsex11pChris Hall2011-03-211-118/+85
| | | | | | Version 0.99.15ex11p A major overhaul.
* Second tranche of updates for pipework branch.Chris Hall2011-02-131-231/+575
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | modified: bgpd/bgp_connection.c modified: bgpd/bgp_debug.c modified: bgpd/bgp_engine.h modified: bgpd/bgp_main.c modified: bgpd/bgp_packet.c modified: bgpd/bgp_peer.c modified: bgpd/bgp_route.c modified: bgpd/bgp_routemap.c modified: bgpd/bgp_session.c modified: bgpd/bgp_vty.c modified: bgpd/bgpd.c modified: bgpd/bgpd.h modified: configure.ac modified: isisd/dict.h modified: isisd/isis_misc.c modified: isisd/isis_routemap.c modified: isisd/isis_spf.c modified: lib/Makefile.am modified: lib/command.c modified: lib/command.h modified: lib/command_execute.h modified: lib/command_parse.c modified: lib/command_parse.h modified: lib/command_queue.c modified: lib/command_queue.h modified: lib/elstring.h modified: lib/heap.c modified: lib/if.c modified: lib/if.h modified: lib/keychain.c modified: lib/keystroke.c modified: lib/keystroke.h modified: lib/list_util.c modified: lib/list_util.h modified: lib/log.c modified: lib/log.h modified: lib/memory.c modified: lib/memory.h modified: lib/memtypes.c modified: lib/misc.h modified: lib/mqueue.c modified: lib/mqueue.h deleted: lib/node_type.h modified: lib/pthread_safe.c modified: lib/qfstring.c modified: lib/qiovec.c modified: lib/qiovec.h modified: lib/qpath.c modified: lib/qpnexus.c modified: lib/qpnexus.h modified: lib/qpselect.c modified: lib/qpthreads.h modified: lib/qstring.c modified: lib/qstring.h modified: lib/qtime.c modified: lib/qtime.h modified: lib/qtimers.c modified: lib/qtimers.h modified: lib/routemap.c modified: lib/symtab.h modified: lib/thread.h deleted: lib/uty.h modified: lib/vector.c modified: lib/vector.h modified: lib/version.h.in modified: lib/vio_fifo.c modified: lib/vio_fifo.h modified: lib/vio_lines.c modified: lib/vio_lines.h modified: lib/vty.c modified: lib/vty.h modified: lib/vty_cli.c modified: lib/vty_cli.h modified: lib/vty_io.c modified: lib/vty_io.h modified: lib/vty_io_basic.c modified: lib/vty_io_basic.h modified: lib/vty_io_file.c modified: lib/vty_io_file.h modified: lib/vty_io_shell.c modified: lib/vty_io_term.c modified: lib/vty_io_term.h modified: lib/vty_local.h modified: lib/vty_pipe.c modified: lib/workqueue.h modified: lib/zebra.h modified: ospf6d/ospf6_lsa.c modified: ripngd/ripngd.c modified: tests/test-list_util.c modified: tests/test-vector.c modified: vtysh/vtysh.c modified: vtysh/vtysh_config.c
* Creation of pipework branchChris Hall2010-12-211-0/+478