File: debug.c

package info (click to toggle)
ipgrab 0.8.2-1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 540 kB
  • ctags: 555
  • sloc: ansic: 4,608; sh: 1,507; makefile: 120
file content (34 lines) | stat: -rw-r--r-- 766 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
/**************************************************************************** 
** File: debug.c
**
** Author: Mike Borella
**
** Comments: Routines printing packets in raw form for debugging
**
** $Log: debug.c,v $
** Revision 1.2  1998/06/12 21:00:58  mborella
** Added log tag
**
*****************************************************************************/

#include <stdio.h>
#include <sys/types.h>
#include "config.h"

/*----------------------------------------------------------------------------
**
** dump_ascii()
**
** Print a packet in ascii format
**
**----------------------------------------------------------------------------
*/

void dump_ascii(u_char *p, u_char *ep)
{
  while(p <= ep)
    {
      printf("[%d]", (u_int8_t) *p);
      p++;
    }
}