From: Jeff Layton <jlayton@kernel.org>
To: fstests@vger.kernel.org
Subject: [PATCH] src/append_reader.c: print more info when it reads bad data
Date: Thu, 5 Nov 2020 10:05:43 -0500 [thread overview]
Message-ID: <20201105150543.403712-1-jlayton@kernel.org> (raw)
When append_reader gets bad data, print the actual and expected values.
This was helpful to me when hunting a failure in generic/069 on ceph
recently.
Signed-off-by: Jeff Layton <jlayton@kernel.org>
---
src/append_reader.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/append_reader.c b/src/append_reader.c
index 6b9e4f68e572..4660268f2f52 100644
--- a/src/append_reader.c
+++ b/src/append_reader.c
@@ -34,7 +34,7 @@ int main(int argc, char **argv)
}
if (d != i) {
- fprintf(stderr, "bad data, offset = %u", i * 4);
+ fprintf(stderr, "bad data, offset = %u, got %d wanted %d\n", i * 4, d, i);
exit(1);
}
}
--
2.28.0
reply other threads:[~2020-11-05 15:05 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201105150543.403712-1-jlayton@kernel.org \
--to=jlayton@kernel.org \
--cc=fstests@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).