Fix hd bug where it truncates homogeneous output when skipping

This commit is contained in:
Neale Pickett 2018-10-16 15:34:02 -06:00
parent c682403a3d
commit 455bdd978d
1 changed files with 1 additions and 1 deletions

2
hd.c
View File

@ -42,7 +42,7 @@ dump(FILE *f)
if (0 == len) if (0 == len)
break; break;
if (p && (0 == memcmp(buf, buf + 16, 16))) { if (p && (len == 16) && (0 == memcmp(buf, buf + 16, 16))) {
if (!skipping) { if (!skipping) {
printf("*\n"); printf("*\n");
skipping = 1; skipping = 1;