summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2009-09-13 18:16:07 +0200
committerMarc Kleine-Budde <mkl@pengutronix.de>2009-09-13 20:52:16 +0200
commit996256943168360c9276cbe53fb75b5cf0abd7b4 (patch)
tree0a0a2230e6f36ffde03edf0f8e4641c5f56da754
parent3a9083492dc1e20cac00f9e964407534a395858f (diff)
downloadcanutils-canutils-3.0.x.tar.gz
[cansequence] add sequence wrap around countercanutils-3.0.x
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
-rw-r--r--src/cansequence.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/cansequence.c b/src/cansequence.c
index f86127b..b787e79 100644
--- a/src/cansequence.c
+++ b/src/cansequence.c
@@ -73,6 +73,7 @@ int main(int argc, char **argv)
};
char *interface = "can0";
unsigned char sequence = 0;
+ int seq_wrap = 0;
int family = PF_CAN, type = SOCK_RAW, proto = CAN_RAW;
int loopcount = 1, infinite = 1;
int use_poll = 0;
@@ -226,7 +227,7 @@ int main(int argc, char **argv)
sequence++;
if (verbose && !sequence)
- printf("sequence wrap around\n");
+ printf("sequence wrap around (%d)\n", seq_wrap++);
}
} else {
@@ -272,7 +273,7 @@ int main(int argc, char **argv)
sequence++;
if (verbose && !sequence)
- printf("sequence wrap around\n");
+ printf("sequence wrap around (%d)\n", seq_wrap++);
}
}