[PATCH] snmp6 stats as %lu

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 03 Apr 2003 04:48:22 -0800 (PST) "David S. Miller" <davem@redhat.com> wrote:

|    From: "Randy.Dunlap" <rddunlap@osdl.org>
|    Date: Wed, 2 Apr 2003 12:27:55 +0000
| 
|    ipv4/proc.c prints SNMP stats using %lu,
|    but ipv6/proc.c prints them using %ld.
|    
|    Is this difference intentional, planned, or an oversight,
|    or something else?
| 
| Looks like an oversight to me, both should use the unsigned format.

Here's the patch, on top of the seq_file conversion.

Thanks,
--
~Randy


patch_name:	snmp6-ulong.patch
patch_version:	2003-04-03.07:57:48
author:		Randy.Dunlap <rddunlap@osdl.org>
description:	modify /proc/net/snmp6 to use %lu instead of %ld for output
product:	Linux
product_versions: 2.5.66
maintainer:	Dave Miller (davem@redhat.com)
diffstat:	=
 net/ipv6/proc.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)


diff -Naur ./net/ipv6/proc.c%SN6ULF ./net/ipv6/proc.c
--- ./net/ipv6/proc.c%SN6ULF	Thu Apr  3 07:56:44 2003
+++ ./net/ipv6/proc.c	Thu Apr  3 07:57:07 2003
@@ -156,7 +156,7 @@
 	int i;
 
 	for (i=0; i<sizeof(snmp6_list)/sizeof(snmp6_list[0]); i++)
-		seq_printf(seq, "%-32s\t%ld\n", snmp6_list[i].name,
+		seq_printf(seq, "%-32s\t%lu\n", snmp6_list[i].name,
 			       fold_field(snmp6_list[i].mib, snmp6_list[i].offset));
 
 	return 0;
-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux