提交 83bc4fa7 编写于 作者: T Tiziano Mueller 提交者: Eric Blake

update virGetVersion description

The current description suggests that you always have to provide
a valid typeVer pointer. But if you want only the libvirt version
it's also possible to set type and typeVer to NULL to skip the
hypervisor part.
上级 ae515576
...@@ -159,6 +159,7 @@ Patches have also been contributed by: ...@@ -159,6 +159,7 @@ Patches have also been contributed by:
Phil Petty <phpetty@cisco.com> Phil Petty <phpetty@cisco.com>
Taku Izumi <izumi.taku@jp.fujitsu.com> Taku Izumi <izumi.taku@jp.fujitsu.com>
Minoru Usui <usui@mxm.nes.nec.co.jp> Minoru Usui <usui@mxm.nes.nec.co.jp>
Tiziano Mueller <dev-zero@gentoo.org>
[....send patches to get your name here....] [....send patches to get your name here....]
......
...@@ -860,14 +860,15 @@ int virStateActive(void) { ...@@ -860,14 +860,15 @@ int virStateActive(void) {
/** /**
* virGetVersion: * virGetVersion:
* @libVer: return value for the library version (OUT) * @libVer: return value for the library version (OUT)
* @type: the type of connection/driver looked at * @type: the type of connection/driver looked at, if @typeVer is not NULL
* @typeVer: return value for the version of the hypervisor (OUT) * @typeVer: optional return value for the version of the hypervisor (OUT)
* *
* Provides two information back, @libVer is the version of the library * Provides information on up to two versions: @libVer is the version of the
* while @typeVer will be the version of the hypervisor type @type against * library and will always be set unless an error occurs, in which case an
* which the library was compiled. If @type is NULL, "Xen" is assumed, if * error code will be returned. If @typeVer is not NULL it will be set to the
* @type is unknown or not available, an error code will be returned and * version of the hypervisor @type against which the library was compiled.
* @typeVer will be 0. * If @type is NULL, "Xen" is assumed, if @type is unknown or not
* available, an error code will be returned and @typeVer will be 0.
* *
* Returns -1 in case of failure, 0 otherwise, and values for @libVer and * Returns -1 in case of failure, 0 otherwise, and values for @libVer and
* @typeVer have the format major * 1,000,000 + minor * 1,000 + release. * @typeVer have the format major * 1,000,000 + minor * 1,000 + release.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册