On Windows Systems ELEMENT_TYPE is already defined
in Winioctl.h this header is included indirectly
in dbus-sysdeps.h. By avoiding the use of the Name
ELEMENT_TYPE it is ensured that config-parser-common.h
can be included together with dbus-sysdeps.h
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
}
else if (strcmp (name, "type") == 0)
{
- return ELEMENT_TYPE;
+ return ELEMENT_CONFIGTYPE;
}
else if (strcmp (name, "fork") == 0)
{
return "servicehelper";
case ELEMENT_INCLUDEDIR:
return "includedir";
- case ELEMENT_TYPE:
+ case ELEMENT_CONFIGTYPE:
return "type";
case ELEMENT_SELINUX:
return "selinux";
ELEMENT_SERVICEDIR,
ELEMENT_SERVICEHELPER,
ELEMENT_INCLUDEDIR,
- ELEMENT_TYPE,
+ /* this is really <type>, but winioctl.h defines ELEMENT_TYPE */
+ ELEMENT_CONFIGTYPE,
ELEMENT_SELINUX,
ELEMENT_ASSOCIATE,
ELEMENT_STANDARD_SESSION_SERVICEDIRS,
return TRUE;
}
- else if (element_type == ELEMENT_TYPE)
+ else if (element_type == ELEMENT_CONFIGTYPE)
{
if (!check_no_attributes (parser, "type", attribute_names, attribute_values, error))
return FALSE;
- if (push_element (parser, ELEMENT_TYPE) == NULL)
+ if (push_element (parser, ELEMENT_CONFIGTYPE) == NULL)
{
BUS_SET_OOM (error);
return FALSE;
case ELEMENT_INCLUDE:
case ELEMENT_USER:
- case ELEMENT_TYPE:
+ case ELEMENT_CONFIGTYPE:
case ELEMENT_LISTEN:
case ELEMENT_PIDFILE:
case ELEMENT_AUTH:
}
break;
- case ELEMENT_TYPE:
+ case ELEMENT_CONFIGTYPE:
{
char *s;