Sync usage with man page.
[netbsd-mini2440.git] / dist / ipf / lib / binprint.c
blob8ec620f650df39e9ca2886765ad832ec3d28d347
1 /* $NetBSD$ */
3 /*
4 * Copyright (C) 2000-2002 by Darren Reed.
6 * See the IPFILTER.LICENCE file for details on licencing.
8 * Id: binprint.c,v 1.8.4.1 2006/06/16 17:20:56 darrenr Exp
9 */
11 #include "ipf.h"
14 void binprint(ptr, size)
15 void *ptr;
16 size_t size;
18 u_char *s;
19 int i, j;
21 for (i = size, j = 0, s = (u_char *)ptr; i; i--, s++) {
22 j++;
23 printf("%02x ", *s);
24 if (j == 16) {
25 printf("\n");
26 j = 0;
29 putchar('\n');
30 (void)fflush(stdout);