Merge remote-tracking branch 'origin/master'
[unleashed/lotheac.git] / usr / src / cmd / ipf / lib / common / printsbuf.c
blobcc13e19b6b758de82aa3e75d0e8f7a61dc552e25
1 /*
2 * Copyright (C) 1993-2005 by Darren Reed.
3 * See the IPFILTER.LICENCE file for details on licencing.
4 */
6 #ifdef IPFILTER_SCAN
8 #include <ctype.h>
9 #include <stdio.h>
10 #include "ipf.h"
11 #include "netinet/ip_scan.h"
13 void printsbuf(buf)
14 char *buf;
16 u_char *s;
17 int i;
19 for (s = (u_char *)buf, i = ISC_TLEN; i; i--, s++) {
20 if (ISPRINT(*s))
21 putchar(*s);
22 else
23 printf("\\%o", *s);
27 #endif