* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*/
-#ifndef lint
-static const char rcsid[] _U_ =
- "@(#) $Header: /tcpdump/master/tcpdump/print-decnet.c,v 1.39 2005-05-06 02:16:26 guy Exp $ (LBL)";
-#endif
-
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "interface.h"
#include "addrtoname.h"
+static const char tstr[] = "[|decnet]";
+
/* Forwards */
static int print_decnet_ctlmsg(const union routehdr *, u_int, u_int);
static void print_t_info(int);
const u_char *nspp;
if (length < sizeof(struct shorthdr)) {
- (void)printf("[|decnet]");
+ (void)printf("%s", tstr);
return;
}
TCHECK2(*ap, sizeof(short));
pktlen = EXTRACT_LE_16BITS(ap);
if (pktlen < sizeof(struct shorthdr)) {
- (void)printf("[|decnet]");
+ (void)printf("%s", tstr);
return;
}
if (pktlen > length) {
- (void)printf("[|decnet]");
+ (void)printf("%s", tstr);
return;
}
length = pktlen;
if (vflag)
(void) printf("[pad:%d] ", padlen);
if (length < padlen + 2) {
- (void)printf("[|decnet]");
+ (void)printf("%s", tstr);
return;
}
TCHECK2(ap[sizeof(short)], padlen);
switch (mflags & RMF_MASK) {
case RMF_LONG:
if (length < sizeof(struct longhdr)) {
- (void)printf("[|decnet]");
+ (void)printf("%s", tstr);
return;
}
TCHECK(rhp->rh_long);
return;
trunc:
- (void)printf("[|decnet]");
+ (void)printf("%s", tstr);
return;
}
return (0);
}
-static struct tok reason2str[] = {
+static const struct tok reason2str[] = {
{ UC_OBJREJECT, "object rejected connect" },
{ UC_RESOURCES, "insufficient resources" },
{ UC_NOSUCHNODE, "unrecognized node name" },
while (x-- > 0) {
c = *dp++;
- safeputchar(c);
+ safeputchar(gndo, c);
}
}
#endif