gio-tool: Do not print settable arguments unless they are any

"Settable arguments:" is printed even if they are not any arguments
to print. Do not print it similarly as it is done for "Writable
namespaces:".

https://bugzilla.gnome.org/show_bug.cgi?id=776169
This commit is contained in:
Ondrej Holy 2016-12-16 14:36:53 +01:00
parent bde2bde411
commit bcb1bfda52

View File

@ -223,6 +223,8 @@ get_writable_info (GFile *file)
return FALSE;
}
if (list->n_infos > 0)
{
g_print (_("Settable attributes:\n"));
for (i = 0; i < list->n_infos; i++)
{
@ -233,6 +235,7 @@ get_writable_info (GFile *file)
(*flags != 0)?", ":"", flags);
g_free (flags);
}
}
g_file_attribute_info_list_unref (list);