X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/16ff6679ae719f0668b9381cebbf866259b47524..f78c60f54a9beb04f1409712ec95b46f2d52a0ab:/print-syslog.c diff --git a/print-syslog.c b/print-syslog.c index f213cf27..d332f67f 100644 --- a/print-syslog.c +++ b/print-syslog.c @@ -14,11 +14,6 @@ * FOR A PARTICULAR PURPOSE. */ -#ifndef lint -static const char rcsid[] _U_ = - "@(#) $Header: /tcpdump/master/tcpdump/print-syslog.c,v 1.1 2004-10-29 11:42:53 hannes Exp $"; -#endif - #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -31,6 +26,8 @@ static const char rcsid[] _U_ = #include "interface.h" #include "extract.h" +static const char tstr[] = "[|syslog]"; + /* * tokenlists and #defines taken from Ethereal - Network traffic analyzer * by Gerald Combs @@ -105,12 +102,12 @@ syslog_print(register const u_char *pptr, register u_int len) TCHECK2(*(pptr+msg_off), 1); } if (*(pptr+msg_off) != '>') { - printf("[|syslog]"); + printf("%s", tstr); return; } msg_off++; } else { - printf("[|syslog]"); + printf("%s", tstr); return; } @@ -136,14 +133,14 @@ syslog_print(register const u_char *pptr, register u_int len) /* print the syslog text in verbose mode */ for (; msg_off < len; msg_off++) { TCHECK2(*(pptr+msg_off), 1); - safeputchar(*(pptr+msg_off)); + safeputchar(gndo, *(pptr + msg_off)); } if (vflag > 1) - print_unknown_data(pptr,"\n\t",len); + print_unknown_data(gndo,pptr,"\n\t",len); return; trunc: - printf("[|syslog]"); + printf("%s", tstr); }