* NEWS docs/* configure.in libvirt.spec.in include/libvirt/libvirt.h:

preparing release of 0.1.2
* src/proxy_internal.c: don't warn on open if using http and not the
  proxy.
Daniel
This commit is contained in:
Daniel Veillard 2006-07-03 15:48:49 +00:00
parent c74976f139
commit 567b42ce6a
8 changed files with 49 additions and 21 deletions

View File

@ -1,3 +1,10 @@
Mon Jul 3 15:41:58 EDT 2006 Daniel Veillard <veillard@redhat.com>
* NEWS docs/* configure.in libvirt.spec.in include/libvirt/libvirt.h:
preparing release of 0.1.2
* src/proxy_internal.c: don't warn on open if using http and not the
proxy.
Mon Jul 3 13:54:03 EDT 2006 Daniel Veillard <veillard@redhat.com>
* libvirt.spec.in proxy/Makefile.am src/proxy_internal.c

7
NEWS
View File

@ -5,6 +5,13 @@
http://libvirt.org/news.html
Releases
0.1.2: Jul 3 2006:
- headers include paths fixup
- proxy mechanism for unpriviledged read-only access by httpu
0.1.1: Jun 21 2006:
- building fixes: ncurses fallback (Jim Fehlig), VPATH builds (Daniel P.
Berrange)

View File

@ -5,7 +5,7 @@ AC_CANONICAL_HOST
LIBVIRT_MAJOR_VERSION=0
LIBVIRT_MINOR_VERSION=1
LIBVIRT_MICRO_VERSION=1
LIBVIRT_MICRO_VERSION=2
LIBVIRT_MICRO_VERSION_SUFFIX=
LIBVIRT_VERSION=$LIBVIRT_MAJOR_VERSION.$LIBVIRT_MINOR_VERSION.$LIBVIRT_MICRO_VERSION$LIBVIRT_MICRO_VERSION_SUFFIX
LIBVIRT_VERSION_INFO=`expr $LIBVIRT_MAJOR_VERSION + $LIBVIRT_MINOR_VERSION`:$LIBVIRT_MICRO_VERSION:$LIBVIRT_MINOR_VERSION

View File

@ -33,6 +33,11 @@ development of libvirt, it is preferable when possible to just use the <a
href="downloads.html">CVS version or snapshot</a>, contact the mailing list
and check the <a href="ChangeLog.html">ChangeLog</a> to gauge progresses.</p>
<h3>0.1.2: Jul 3 2006</h3>
<ul>
<li> headers include paths fixup
<li> proxy mechanism for unpriviledged read-only access by httpu
</ul>
<h3>0.1.1: Jun 21 2006</h3>
<ul>
<li> building fixes: ncurses fallback (Jim Fehlig), VPATH builds (Daniel P.

View File

@ -2,7 +2,9 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /><link rel="stylesheet" type="text/css" href="libvirt.css" /><link rel="SHORTCUT ICON" href="/32favicon.png" /><title>Releases</title></head><body><div id="container"><div id="intro"><div id="adjustments"></div><div id="pageHeader"></div><div id="content2"><h1 class="style1">Releases</h1><p>Here is the list of official releases, however since it is early on in the
development of libvirt, it is preferable when possible to just use the <a href="downloads.html">CVS version or snapshot</a>, contact the mailing list
and check the <a href="ChangeLog.html">ChangeLog</a> to gauge progresses.</p><h3>0.1.1: Jun 21 2006</h3><ul><li> building fixes: ncurses fallback (Jim Fehlig), VPATH builds (Daniel P.
and check the <a href="ChangeLog.html">ChangeLog</a> to gauge progresses.</p><h3>0.1.2: Jul 3 2006</h3><ul><li> headers include paths fixup
</li><li> proxy mechanism for unpriviledged read-only access by httpu
</li></ul><h3>0.1.1: Jun 21 2006</h3><ul><li> building fixes: ncurses fallback (Jim Fehlig), VPATH builds (Daniel P.
Berrange)
</li><li> driver cleanups: new entry points, cleanup of libvirt.c (with Daniel P.
Berrange)

View File

@ -184,7 +184,7 @@ typedef virNodeInfo *virNodeInfoPtr;
* version * 1,000,000 + minor * 1000 + micro
*/
#define LIBVIR_VERSION_NUMBER 1001
#define LIBVIR_VERSION_NUMBER 1002
int virGetVersion (unsigned long *libVer,
const char *type,

View File

@ -104,6 +104,10 @@ rm -fr %{buildroot}
%doc docs/examples/python
%changelog
* Mon Jul 3 2006 Daniel Veillard <veillard@redhat.com> 0.1.2-1
- added a proxy mechanism for read only access using httpu
- fixed header includes paths
* Wed Jun 21 2006 Daniel Veillard <veillard@redhat.com> 0.1.1-1
- extend and cleanup the driver infrastructure and code
- python examples

View File

@ -106,7 +106,7 @@ virProxyError(virConnectPtr conn, virErrorNumber error, const char *info)
return;
errmsg = __virErrorMsg(error, info);
__virRaiseError(conn, NULL, VIR_FROM_XEND, error, VIR_ERR_ERROR,
__virRaiseError(conn, NULL, VIR_FROM_PROXY, error, VIR_ERR_ERROR,
errmsg, info, NULL, 0, 0, errmsg, info);
}
@ -285,13 +285,14 @@ virProxyCloseClientSocket(int fd) {
* @fd: the socket
* @buffer: the target memory area
* @len: the lenght in bytes
* @quiet: quiet access
*
* Process a read from a client socket
*
* Returns the number of byte read or -1 in case of error.
*/
static int
virProxyReadClientSocket(int fd, char *buffer, int len) {
virProxyReadClientSocket(int fd, char *buffer, int len, int quiet) {
int ret;
if ((fd < 0) || (buffer == NULL) || (len < 0))
@ -305,7 +306,8 @@ retry:
fprintf(stderr, "read socket %d interrupted\n", fd);
goto retry;
}
fprintf(stderr, "Failed to read socket %d\n", fd);
if (!quiet)
fprintf(stderr, "Failed to read socket %d\n", fd);
return(-1);
}
@ -372,7 +374,7 @@ xenProxyClose(virConnectPtr conn) {
static int
xenProxyCommand(virConnectPtr conn, virProxyPacketPtr request,
virProxyFullPacketPtr answer) {
virProxyFullPacketPtr answer, int quiet) {
static int serial = 0;
int ret;
virProxyPacketPtr res = NULL;
@ -396,7 +398,7 @@ retry:
if (answer == NULL) {
/* read in situ */
ret = virProxyReadClientSocket(conn->proxy, (char *) request,
sizeof(virProxyPacket));
sizeof(virProxyPacket), quiet);
if (ret < 0)
return(-1);
if (ret != sizeof(virProxyPacket)) {
@ -417,7 +419,7 @@ retry:
} else {
/* read in packet provided */
ret = virProxyReadClientSocket(conn->proxy, (char *) answer,
sizeof(virProxyPacket));
sizeof(virProxyPacket), quiet);
if (ret < 0)
return(-1);
if (ret != sizeof(virProxyPacket)) {
@ -439,7 +441,7 @@ retry:
if (res->len > sizeof(virProxyPacket)) {
ret = virProxyReadClientSocket(conn->proxy,
(char *) &(answer->extra.arg[0]),
res->len - ret);
res->len - ret, quiet);
if (ret != (int) (res->len - sizeof(virProxyPacket))) {
fprintf(stderr,
"Communication error with proxy: got %d bytes of %d\n",
@ -502,9 +504,10 @@ xenProxyOpen(virConnectPtr conn, const char *name, int flags)
memset(&req, 0, sizeof(req));
req.command = VIR_PROXY_NONE;
req.len = sizeof(req);
ret = xenProxyCommand(conn, &req, NULL);
ret = xenProxyCommand(conn, &req, NULL, 1);
if ((ret < 0) || (req.command != VIR_PROXY_NONE)) {
virProxyError(conn, VIR_ERR_OPERATION_FAILED, __FUNCTION__);
if (!(flags & VIR_DRV_OPEN_QUIET))
virProxyError(conn, VIR_ERR_OPERATION_FAILED, __FUNCTION__);
xenProxyClose(conn);
return(-1);
}
@ -545,7 +548,7 @@ xenProxyGetVersion(virConnectPtr conn, unsigned long *hvVer)
memset(&req, 0, sizeof(req));
req.command = VIR_PROXY_VERSION;
req.len = sizeof(req);
ret = xenProxyCommand(conn, &req, NULL);
ret = xenProxyCommand(conn, &req, NULL, 0);
if (ret < 0) {
xenProxyClose(conn);
return(-1);
@ -583,7 +586,7 @@ xenProxyListDomains(virConnectPtr conn, int *ids, int maxids)
memset(&req, 0, sizeof(req));
req.command = VIR_PROXY_LIST;
req.len = sizeof(req);
ret = xenProxyCommand(conn, &req, &ans);
ret = xenProxyCommand(conn, &req, &ans, 0);
if (ret < 0) {
xenProxyClose(conn);
return(-1);
@ -623,7 +626,7 @@ xenProxyNumOfDomains(virConnectPtr conn)
memset(&req, 0, sizeof(req));
req.command = VIR_PROXY_NUM_DOMAIN;
req.len = sizeof(req);
ret = xenProxyCommand(conn, &req, NULL);
ret = xenProxyCommand(conn, &req, NULL, 0);
if (ret < 0) {
xenProxyClose(conn);
return(-1);
@ -655,7 +658,7 @@ xenProxyDomainGetDomMaxMemory(virConnectPtr conn, int id)
req.command = VIR_PROXY_MAX_MEMORY;
req.data.arg = id;
req.len = sizeof(req);
ret = xenProxyCommand(conn, &req, NULL);
ret = xenProxyCommand(conn, &req, NULL, 0);
if (ret < 0) {
xenProxyClose(conn);
return(-1);
@ -716,7 +719,7 @@ xenProxyDomainGetInfo(virDomainPtr domain, virDomainInfoPtr info)
req.command = VIR_PROXY_DOMAIN_INFO;
req.data.arg = domain->handle;
req.len = sizeof(req);
ret = xenProxyCommand(domain->conn, &req, &ans);
ret = xenProxyCommand(domain->conn, &req, &ans, 0);
if (ret < 0) {
xenProxyClose(domain->conn);
return(-1);
@ -761,7 +764,7 @@ xenProxyLookupByID(virConnectPtr conn, int id)
req.command = VIR_PROXY_LOOKUP_ID;
req.data.arg = id;
req.len = sizeof(req);
ret = xenProxyCommand(conn, &req, &ans);
ret = xenProxyCommand(conn, &req, &ans, 0);
if (ret < 0) {
xenProxyClose(conn);
return(NULL);
@ -809,7 +812,7 @@ xenProxyLookupByUUID(virConnectPtr conn, const unsigned char *uuid)
memset(&req, 0, sizeof(virProxyPacket));
req.command = VIR_PROXY_LOOKUP_UUID;
req.len = sizeof(virProxyPacket) + 16;
ret = xenProxyCommand(conn, (virProxyPacketPtr) &req, &req);
ret = xenProxyCommand(conn, (virProxyPacketPtr) &req, &req, 0);
if (ret < 0) {
xenProxyClose(conn);
return(NULL);
@ -861,7 +864,7 @@ xenProxyDomainLookupByName(virConnectPtr conn, const char *name)
req.command = VIR_PROXY_LOOKUP_NAME;
req.len = sizeof(virProxyPacket) + len + 1;
strcpy(&req.extra.str[0], name);
ret = xenProxyCommand(conn, (virProxyPacketPtr) &req, &req);
ret = xenProxyCommand(conn, (virProxyPacketPtr) &req, &req, 0);
if (ret < 0) {
xenProxyClose(conn);
return(NULL);
@ -906,7 +909,7 @@ xenProxyNodeGetInfo(virConnectPtr conn, virNodeInfoPtr info) {
req.command = VIR_PROXY_NODE_INFO;
req.data.arg = 0;
req.len = sizeof(req);
ret = xenProxyCommand(conn, &req, &ans);
ret = xenProxyCommand(conn, &req, &ans, 0);
if (ret < 0) {
xenProxyClose(conn);
return(-1);