pieusb: Fix [-Wmisleading-indentation] compiler warning

The indentation has been aligned what is used inside the while loop.
The function appears to have been copied from elsewhere and slightly
modified.

The msg variable is set to NULL inside the if branch for efficiency
only.
merge-requests/1/head
Olaf Meeuwissen 2017-06-26 18:01:34 +09:00
rodzic 3191056a4c
commit 08e1ba1286
1 zmienionych plików z 8 dodań i 6 usunięć

Wyświetl plik

@ -176,11 +176,13 @@ _hexdump(char *msg, unsigned char *ptr, int size)
clipped = size;
size = 128;
}
while (size-- > 0)
{
if ((count % 16) == 0)
fprintf (stderr, "%s\t%08lx:", msg?msg:"", start);
msg = NULL;
while (size-- > 0)
{
if ((count % 16) == 0)
{
fprintf (stderr, "%s\t%08lx:", msg?msg:"", start);
msg = NULL;
}
fprintf (stderr, " %02x", *ptr++);
count++;
start++;
@ -207,7 +209,7 @@ _hexdump(char *msg, unsigned char *ptr, int size)
if ((count % 16) != 0)
fprintf (stderr, "\n");
if (clipped > 0)
fprintf (stderr, "\t%08lx bytes clipped\n", clipped);
fprintf (stderr, "\t%08lx bytes clipped\n", clipped);
fflush(stderr);
return;