Date: Mon, 30 Nov 1998 21:13:21 +0100 (CET) From: marcel@scc.nl To: FreeBSD-gnats-submit@FreeBSD.ORG Subject: ports/8908: ucd-snmp-3.5.3 on FreeBSD-current Message-ID: <199811302013.VAA68220@scones.sup.scc.nl>
next in thread | raw e-mail | index | archive | help
>Number: 8908 >Category: ports >Synopsis: snmpd does not return ifPhysAddress on GET >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Nov 30 12:20:01 PST 1998 >Last-Modified: >Originator: Marcel Moolenaar >Organization: SCC vof >Release: FreeBSD 3.0-CURRENT i386 >Environment: FreeBSD scones.sup.scc.nl 3.0-CURRENT FreeBSD 3.0-CURRENT #9: Fri Nov 27 00:08:21 CET 1998 marcel@scones.sup.scc.nl:/usr/src/sys/compile/SCONES i386 >Description: snmpd does not return OID "system.interfaces.ifNumber.ifTable.ifEntry.ifPhysAddress" when requested by a SNMP manager. Cause: sysctl(3) semantics has been changed for the interfaces in -current. >How-To-Repeat: n/a >Fix: Apply the following patch. *** agent/mibgroup/mibII/interfaces.c.orig Mon Sep 28 22:09:06 1998 --- agent/mibgroup/mibII/interfaces.c Mon Nov 30 20:16:01 1998 *************** *** 1676,1685 **** --- 1676,1693 ---- physaddrbuf = 0; } ifm = (struct if_msghdr *)rtm; + #ifdef freebsd3 + if (physaddrs != 0) physaddrs[naddrs] = (void*)(ifm + 1); + naddrs++; + #endif ilen -= ifm->ifm_msglen; cp += ifm->ifm_msglen; rtm = (struct rt_msghdr *)cp; while (ilen > 0 && rtm->rtm_type == RTM_NEWADDR) { + #ifdef freebsd3 + ilen -= rtm->rtm_msglen; + cp += rtm->rtm_msglen; + #else int is_alias = 0; ifam = (struct ifa_msghdr *)rtm; ilen -= sizeof(*ifam); *************** *** 1702,1707 **** --- 1710,1716 ---- } sa = (struct sockaddr *)cp; } + #endif rtm = (struct rt_msghdr *)cp; } } >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199811302013.VAA68220>