diff options
author | Otto Moerbeek <otto@cvs.openbsd.org> | 2004-01-20 09:00:42 +0000 |
---|---|---|
committer | Otto Moerbeek <otto@cvs.openbsd.org> | 2004-01-20 09:00:42 +0000 |
commit | a0bfce05e5e241954cc05dbd8f8759c303f380c9 (patch) | |
tree | 02bad9a33a94f15e09f0bcd98c3698c58d88a583 /usr.sbin/tcpdump | |
parent | 3da99fe3906b68ca8e1ca3a224a2f3ed7d1698da (diff) |
If you go through the trouble of caching the name of the last printed
rpc num, you might as well use it later too. ok canacar@
Diffstat (limited to 'usr.sbin/tcpdump')
-rw-r--r-- | usr.sbin/tcpdump/print-sunrpc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/tcpdump/print-sunrpc.c b/usr.sbin/tcpdump/print-sunrpc.c index 961c3bc1e37..451fba80d08 100644 --- a/usr.sbin/tcpdump/print-sunrpc.c +++ b/usr.sbin/tcpdump/print-sunrpc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: print-sunrpc.c,v 1.13 2002/02/19 19:39:40 millert Exp $ */ +/* $OpenBSD: print-sunrpc.c,v 1.14 2004/01/20 09:00:41 otto Exp $ */ /* * Copyright (c) 1992, 1993, 1994, 1995, 1996 @@ -23,7 +23,7 @@ #ifndef lint static const char rcsid[] = - "@(#) $Header: /cvs/OpenBSD/src/usr.sbin/tcpdump/print-sunrpc.c,v 1.13 2002/02/19 19:39:40 millert Exp $ (LBL)"; + "@(#) $Header: /cvs/OpenBSD/src/usr.sbin/tcpdump/print-sunrpc.c,v 1.14 2004/01/20 09:00:41 otto Exp $ (LBL)"; #endif #include <sys/param.h> @@ -111,6 +111,7 @@ progstr(prog) if (lastprog != 0 && prog == lastprog) return (buf); + lastprog = prog; rp = getrpcbynumber(prog); if (rp == NULL) snprintf(buf, sizeof(buf), "#%u", prog); |