/* This file is auto-generated from ../src/rpc/virnetprotocol.x */

#include <config.h>
#include "virnetprotocol.h"


void xdr_virNetMessageHeader_clear(virNetMessageHeader *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageHeader, (char *)objp);
}


void xdr_virNetMessageUUID_clear(virNetMessageUUID *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageUUID, (char *)objp);
}


void xdr_virNetMessageNonnullString_clear(virNetMessageNonnullString *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageNonnullString, (char *)objp);
}


void xdr_virNetMessageString_clear(virNetMessageString *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageString, (char *)objp);
}


void xdr_virNetMessageNonnullDomain_clear(virNetMessageNonnullDomain *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageNonnullDomain, (char *)objp);
}


void xdr_virNetMessageNonnullNetwork_clear(virNetMessageNonnullNetwork *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageNonnullNetwork, (char *)objp);
}


void xdr_virNetMessageDomain_clear(virNetMessageDomain *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageDomain, (char *)objp);
}


void xdr_virNetMessageNetwork_clear(virNetMessageNetwork *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageNetwork, (char *)objp);
}


void xdr_virNetMessageError_clear(virNetMessageError *objp)
{
    xdr_free((xdrproc_t)xdr_virNetMessageError, (char *)objp);
}


void xdr_virNetStreamHole_clear(virNetStreamHole *objp)
{
    xdr_free((xdrproc_t)xdr_virNetStreamHole, (char *)objp);
}

bool_t
xdr_virNetMessageType(XDR *xdrs, virNetMessageType *objp)
{
    if (!xdr_enum(xdrs, (enum_t *)objp))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageStatus(XDR *xdrs, virNetMessageStatus *objp)
{
    if (!xdr_enum(xdrs, (enum_t *)objp))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageHeader(XDR *xdrs, virNetMessageHeader *objp)
{
    if (!xdr_u_int(xdrs, &objp->prog))
        return FALSE;
    if (!xdr_u_int(xdrs, &objp->vers))
        return FALSE;
    if (!xdr_int(xdrs, &objp->proc))
        return FALSE;
    if (!xdr_virNetMessageType(xdrs, &objp->type))
        return FALSE;
    if (!xdr_u_int(xdrs, &objp->serial))
        return FALSE;
    if (!xdr_virNetMessageStatus(xdrs, &objp->status))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageUUID(XDR *xdrs, virNetMessageUUID objp)
{
    if (!xdr_opaque(xdrs, objp, VIR_UUID_BUFLEN))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageNonnullString(XDR *xdrs, virNetMessageNonnullString *objp)
{
    if (!xdr_string(xdrs, objp, VIR_NET_MESSAGE_STRING_MAX))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageString(XDR *xdrs, virNetMessageString *objp)
{
    if (!xdr_pointer(xdrs, (char **)objp, sizeof(virNetMessageNonnullString), (xdrproc_t)xdr_virNetMessageNonnullString))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageNonnullDomain(XDR *xdrs, virNetMessageNonnullDomain *objp)
{
    if (!xdr_virNetMessageNonnullString(xdrs, &objp->name))
        return FALSE;
    if (!xdr_virNetMessageUUID(xdrs, objp->uuid))
        return FALSE;
    if (!xdr_int(xdrs, &objp->id))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageNonnullNetwork(XDR *xdrs, virNetMessageNonnullNetwork *objp)
{
    if (!xdr_virNetMessageNonnullString(xdrs, &objp->name))
        return FALSE;
    if (!xdr_virNetMessageUUID(xdrs, objp->uuid))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageDomain(XDR *xdrs, virNetMessageDomain *objp)
{
    if (!xdr_pointer(xdrs, (char **)objp, sizeof(virNetMessageNonnullDomain), (xdrproc_t)xdr_virNetMessageNonnullDomain))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageNetwork(XDR *xdrs, virNetMessageNetwork *objp)
{
    if (!xdr_pointer(xdrs, (char **)objp, sizeof(virNetMessageNonnullNetwork), (xdrproc_t)xdr_virNetMessageNonnullNetwork))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetMessageError(XDR *xdrs, virNetMessageError *objp)
{
    if (!xdr_int(xdrs, &objp->code))
        return FALSE;
    if (!xdr_int(xdrs, &objp->domain))
        return FALSE;
    if (!xdr_virNetMessageString(xdrs, &objp->message))
        return FALSE;
    if (!xdr_int(xdrs, &objp->level))
        return FALSE;
    if (!xdr_virNetMessageDomain(xdrs, &objp->dom))
        return FALSE;
    if (!xdr_virNetMessageString(xdrs, &objp->str1))
        return FALSE;
    if (!xdr_virNetMessageString(xdrs, &objp->str2))
        return FALSE;
    if (!xdr_virNetMessageString(xdrs, &objp->str3))
        return FALSE;
    if (!xdr_int(xdrs, &objp->int1))
        return FALSE;
    if (!xdr_int(xdrs, &objp->int2))
        return FALSE;
    if (!xdr_virNetMessageNetwork(xdrs, &objp->net))
        return FALSE;
    return TRUE;
}

bool_t
xdr_virNetStreamHole(XDR *xdrs, virNetStreamHole *objp)
{
    if (!xdr_int64_t(xdrs, &objp->length))
        return FALSE;
    if (!xdr_u_int(xdrs, &objp->flags))
        return FALSE;
    return TRUE;
}

