10 #include <atalk/util.h>
12 static const char hexdig[] = "0123456789ABCDEF";
17 void bprint( data, len )
21 char xout[ BPXLEN ], aout[ BPALEN ];
24 memset( xout, 0, BPXLEN );
25 memset( aout, 0, BPALEN );
27 for ( i = 0; len; len--, data++, i++ ) {
29 printf( "%-48s\t%-16s\n", xout, aout );
30 memset( xout, 0, BPXLEN );
31 memset( aout, 0, BPALEN );
35 if (isprint( (unsigned char)*data )) {
41 xout[ (i*3) ] = hexdig[ ( *data & 0xf0 ) >> 4 ];
42 xout[ (i*3) + 1 ] = hexdig[ *data & 0x0f ];
43 xout[ (i*3) + 2 ] = ' ';
47 printf( "%-48s\t%-16s\n", xout, aout );