Don't compile packet dumping code by default.
Bug: 7664960 Change-Id: Ieb56bcc010d0e12264d43e0a0dfcb1beb479d4e2
This commit is contained in:
parent
70aba57df0
commit
f68200ab1a
2 changed files with 6 additions and 1 deletions
2
debug.h
2
debug.h
|
|
@ -18,7 +18,7 @@
|
|||
#ifndef __DEBUG_H__
|
||||
#define __DEBUG_H__
|
||||
|
||||
// set to 1 to enable debug logging
|
||||
// set to 1 to enable debug logging and packet dumping.
|
||||
#define CLAT_DEBUG 0
|
||||
|
||||
#endif /* __DEBUG_H__ */
|
||||
|
|
|
|||
5
dump.c
5
dump.c
|
|
@ -28,10 +28,13 @@
|
|||
#include <netinet/icmp6.h>
|
||||
#include <linux/icmp.h>
|
||||
|
||||
#include "debug.h"
|
||||
#include "checksum.h"
|
||||
#include "clatd.h"
|
||||
#include "logging.h"
|
||||
|
||||
#if CLAT_DEBUG
|
||||
|
||||
/* print ip header */
|
||||
void dump_ip(struct iphdr *header) {
|
||||
u_int16_t frag_flags;
|
||||
|
|
@ -223,3 +226,5 @@ void logcat_hexdump(const char *info, const char *data, size_t len) {
|
|||
|
||||
logmsg(ANDROID_LOG_WARN,"info %s len %d data %s", info, len, output);
|
||||
}
|
||||
|
||||
#endif // CLAT_DEBUG
|
||||
|
|
|
|||
Loading…
Reference in a new issue