mirror of
https://git.proxmox.com/git/fwupd
synced 2025-08-05 10:27:11 +00:00
fu-util-common: strip all trailing whitespace in XML description
Before: ``` └─Thunderbolt controller in Dell dock: │ Device ID: 42b9e069d0b5515065cf4a32cec39552861439c9 │ Description: Updating the dock improves performance. │ │ Flags: updatable|require-ac|registered │ └─Thunderbolt controller Update: Version: 43.00 Summary: Update for the Thunderbolt controller within a Dell dock License: proprietary Size: 409.6 kB Vendor: Dell Inc. Flags: trusted-payload ``` After: ``` └─Thunderbolt controller in Dell dock: │ Device ID: 42b9e069d0b5515065cf4a32cec39552861439c9 │ Description: Updating the dock improves performance. │ Flags: updatable|require-ac|registered │ └─Thunderbolt controller Update: Version: 43.00 Summary: Update for the Thunderbolt controller within a Dell dock License: proprietary Size: 409.6 kB Vendor: Dell Inc. Flags: trusted-payload ```
This commit is contained in:
parent
ef3c766e1f
commit
26563d750f
@ -824,12 +824,8 @@ fu_util_convert_description (const gchar *xml, GError **error)
|
||||
g_set_object (&n, n2);
|
||||
}
|
||||
|
||||
/* remove extra newline */
|
||||
if (str->len > 0)
|
||||
g_string_truncate (str, str->len - 1);
|
||||
|
||||
/* success */
|
||||
return g_string_free (g_steal_pointer (&str), FALSE);
|
||||
return fu_common_strstrip (str->str);
|
||||
}
|
||||
|
||||
static gchar *
|
||||
|
Loading…
Reference in New Issue
Block a user