]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commit
virsh: split out virsh-domain.c
authorEric Blake <eblake@redhat.com>
Sat, 18 Aug 2012 04:00:42 +0000 (22:00 -0600)
committerEric Blake <eblake@redhat.com>
Sat, 18 Aug 2012 04:22:42 +0000 (22:22 -0600)
commitf4a7b87de0d36acf148147edc108e4a8c73ba353
tree182fabc8fbb68122898a6bfbe7f6829e29448fd1
parentc2e494cc570540827d3ba8562a56349686bc2cc2
virsh: split out virsh-domain.c

The virsh-domain.c file was pretty self-contained; the only
entry point was the table of command definitions.  The bulk
of this patch is making more functions in virsh.c reusable.
A later patch will clean up poor naming choices.

* tools/Makefile.am (virsh_SOURCES): Build virsh-domain.c.
* tools/virsh-domain.h: New file.
* tools/virsh.h (virshReportError, vshResetLibvirtError)
(vshAskReedit, vshStreamSink): Declare.
* tools/virsh.c: Switch from using .c to .h.
(virshReportError, vshResetLibvirtError, vshAskReedit)
(vshStreamSink, prettyCapacity): Export.
(vshCatchInt): Move...
* tools/virsh-domain.c: ...into sole user.  Use header.
tools/Makefile.am
tools/virsh-domain.c
tools/virsh-domain.h [new file with mode: 0644]
tools/virsh.c
tools/virsh.h