mirror of
https://git.proxmox.com/git/fwupd
synced 2025-05-21 15:34:59 +00:00
dfu: Fix listing devices using the ST reference bootloader
This commit is contained in:
parent
877df1dda3
commit
c6a8deeb4c
@ -213,13 +213,10 @@ dfu_target_parse_sector (DfuTarget *target,
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* optional spaces */
|
||||
while (tmp[0] == ' ')
|
||||
tmp++;
|
||||
|
||||
/* get multiplier */
|
||||
switch (tmp[0]) {
|
||||
case 'B': /* byte */
|
||||
case ' ': /* byte, ST reference bootloader :/ */
|
||||
break;
|
||||
case 'K': /* Kilo */
|
||||
sector_size *= 0x400;
|
||||
|
@ -1817,7 +1817,9 @@ dfu_tool_list_target (DfuTarget *target)
|
||||
if (tmp != NULL) {
|
||||
/* TRANSLATORS: interface name, e.g. "Flash" */
|
||||
dfu_tool_print_indent (_("Name"), tmp, 2);
|
||||
} else {
|
||||
} else if (!g_error_matches (error_local,
|
||||
DFU_ERROR,
|
||||
DFU_ERROR_NOT_FOUND)) {
|
||||
g_autofree gchar *str = NULL;
|
||||
str = g_strdup_printf ("Error: %s", error_local->message);
|
||||
dfu_tool_print_indent (_("Name"), str, 2);
|
||||
|
Loading…
Reference in New Issue
Block a user