summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libnm-core/nm-utils.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/libnm-core/nm-utils.c b/libnm-core/nm-utils.c
index 85f7b4a673..4127abb54d 100644
--- a/libnm-core/nm-utils.c
+++ b/libnm-core/nm-utils.c
@@ -2591,11 +2591,21 @@ _string_append_tc_action (GString *string, NMTCAction *action, GError **error)
{
const char *kind = nm_tc_action_get_kind (action);
gs_free char *str = NULL;
+ const NMVariantAttributeSpec *const *attrs;
+
+ if (nm_streq (kind, "simple"))
+ attrs = tc_action_simple_attribute_spec;
+ else if (nm_streq (kind, "mirred"))
+ attrs = tc_action_mirred_attribute_spec;
+ else
+ attrs = NULL;
+
g_string_append (string, kind);
- str = nm_utils_format_variant_attributes (_nm_tc_action_get_attributes (action),
- ' ', ' ');
+ str = _nm_utils_format_variant_attributes (_nm_tc_action_get_attributes (action),
+ attrs,
+ ' ', ' ');
if (str) {
g_string_append_c (string, ' ');
g_string_append (string, str);