summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2006-11-28 17:37:49 -0500
committerKristian Høgsberg <krh@redhat.com>2006-11-28 17:37:49 -0500
commitdf02d8c052e86a19fc393a0d3edb06235b9bd579 (patch)
tree12799a848f79a77e39f899a67af7026c43354704
parent26472096ecfe60d43eefc4ccb43b103a36fa3966 (diff)
Distinguish between phy-packets and 0-length iso data.
-rw-r--r--nosy-dump.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/nosy-dump.c b/nosy-dump.c
index c070e27..00dd1e1 100644
--- a/nosy-dump.c
+++ b/nosy-dump.c
@@ -934,7 +934,7 @@ print_packet(unsigned long *data, size_t length)
printf("]");
}
- else if (length == sizeof(struct phy_packet)) {
+ else if (length == sizeof(struct phy_packet) && data[1] == ~data[2]) {
struct phy_packet *pp = (struct phy_packet *) data;
/* phy packet are 3 quadlets: the 1 quadlet payload,
@@ -1018,7 +1018,7 @@ print_stats(unsigned long *data, size_t length)
bus_reset_count++;
else if (length < sizeof(struct phy_packet))
short_packet_count++;
- else if (length == sizeof(struct phy_packet))
+ else if (length == sizeof(struct phy_packet) && data[1] == ~data[2])
phy_packet_count++;
else {
struct link_packet *packet = (struct link_packet *) data;