Fix --with-xen-proxy related compile error

Move virDomainChrTargetTypeToString out of the #ifndef PROXY
block, because it's used outside of it.
This commit is contained in:
Matthias Bolte 2010-07-29 16:03:48 +02:00
parent 56b408231a
commit 6bd5a7c200

View File

@ -2441,26 +2441,6 @@ out:
return ret;
}
static const char *
virDomainChrTargetTypeToString(int deviceType,
int targetType)
{
const char *type = NULL;
switch (deviceType) {
case VIR_DOMAIN_CHR_DEVICE_TYPE_CHANNEL:
type = virDomainChrChannelTargetTypeToString(targetType);
break;
case VIR_DOMAIN_CHR_DEVICE_TYPE_CONSOLE:
type = virDomainChrConsoleTargetTypeToString(targetType);
break;
default:
break;
}
return type;
}
static int
virDomainChrDefParseTargetXML(virCapsPtr caps,
virDomainChrDefPtr def,
@ -3952,6 +3932,26 @@ virDomainDeviceDefPtr virDomainDeviceDefParse(virCapsPtr caps,
#endif /* !PROXY */
static const char *
virDomainChrTargetTypeToString(int deviceType,
int targetType)
{
const char *type = NULL;
switch (deviceType) {
case VIR_DOMAIN_CHR_DEVICE_TYPE_CHANNEL:
type = virDomainChrChannelTargetTypeToString(targetType);
break;
case VIR_DOMAIN_CHR_DEVICE_TYPE_CONSOLE:
type = virDomainChrConsoleTargetTypeToString(targetType);
break;
default:
break;
}
return type;
}
static void
virVirtualPortProfileFormat(virBufferPtr buf,
virVirtualPortProfileParamsPtr virtPort,