diff --git a/repos/os/src/init/config.xsd b/repos/os/src/init/config.xsd
index 9c1a5c6c8e..352fc1decd 100644
--- a/repos/os/src/init/config.xsd
+++ b/repos/os/src/init/config.xsd
@@ -16,6 +16,7 @@
+
diff --git a/repos/os/src/init/utils.h b/repos/os/src/init/utils.h
index e86a4e6244..07d2910e0d 100644
--- a/repos/os/src/init/utils.h
+++ b/repos/os/src/init/utils.h
@@ -69,12 +69,17 @@ namespace Init {
if (!service_matches)
return false;
+ typedef String Label;
+
+ char const *unscoped_attr = "unscoped_label";
+ char const *label_last_attr = "label_last";
+
bool const route_depends_on_child_provided_label =
service_node.has_attribute("label") ||
service_node.has_attribute("label_prefix") ||
- service_node.has_attribute("label_suffix");
+ service_node.has_attribute("label_suffix") ||
+ service_node.has_attribute(label_last_attr);
- char const *unscoped_attr = "unscoped_label";
if (service_node.has_attribute(unscoped_attr)) {
/*
@@ -84,10 +89,12 @@ namespace Init {
if (route_depends_on_child_provided_label)
warning("service node contains both scoped and unscoped label attributes");
- typedef String Label;
return label == service_node.attribute_value(unscoped_attr, Label());
}
+ if (service_node.has_attribute(label_last_attr))
+ return service_node.attribute_value(label_last_attr, Label()) == label.last_element();
+
if (!route_depends_on_child_provided_label)
return true;