mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-31 18:20:10 +01:00
nmcli: output just the raw value of vlan.flags when in terse mode
This commit is contained in:
parent
3e3d36450c
commit
39f1d44ec8
1 changed files with 5 additions and 2 deletions
|
|
@ -900,10 +900,13 @@ bytes_to_string (GBytes *bytes)
|
|||
}
|
||||
|
||||
static char *
|
||||
vlan_flags_to_string (guint32 flags)
|
||||
vlan_flags_to_string (guint32 flags, NmcPropertyGetType get_type)
|
||||
{
|
||||
GString *flag_str;
|
||||
|
||||
if (get_type == NMC_PROPERTY_GET_PARSABLE)
|
||||
return g_strdup_printf ("%u", flags);
|
||||
|
||||
if (flags == 0)
|
||||
return g_strdup (_("0 (NONE)"));
|
||||
|
||||
|
|
@ -4724,7 +4727,7 @@ static char *
|
|||
nmc_property_vlan_get_flags (NMSetting *setting, NmcPropertyGetType get_type)
|
||||
{
|
||||
NMSettingVlan *s_vlan = NM_SETTING_VLAN (setting);
|
||||
return vlan_flags_to_string (nm_setting_vlan_get_flags (s_vlan));
|
||||
return vlan_flags_to_string (nm_setting_vlan_get_flags (s_vlan), get_type);
|
||||
}
|
||||
|
||||
static char *
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue