- /* The local port always has type "internal" unless the bridge is of
- * type "dummy". Other ports take their type from the database and
- * default to "system" if none is specified. */
- if (!strcmp(iface->name, br->name)) {
- return !strcmp(br->datapath_type, "dummy") ? "dummy" : "internal";
+ const char *type;
+
+ /* The local port always has type "internal". Other ports take
+ * their type from the database and default to "system" if none is
+ * specified. */
+ if (iface_is_internal(iface, br)) {
+ type = "internal";