diff options
author | harti <harti@FreeBSD.org> | 2016-01-21 16:11:20 +0000 |
---|---|---|
committer | harti <harti@FreeBSD.org> | 2016-01-21 16:11:20 +0000 |
commit | 9695459665ca68a66ba2e9f04d4bf57787e95b34 (patch) | |
tree | 4d51c55ca0675baf4673ad2810858addce99e2cb /contrib/bsnmp/snmp_mibII/mibII.h | |
parent | d6a31ebe03d5c26e102e7ef256ccdb0bbc1f438f (diff) | |
download | FreeBSD-src-9695459665ca68a66ba2e9f04d4bf57787e95b34.zip FreeBSD-src-9695459665ca68a66ba2e9f04d4bf57787e95b34.tar.gz |
Fill the ifAlias leaf of the ifXTable with the interface description
if there is one available and it fits into the maximum size (64 characters).
Diffstat (limited to 'contrib/bsnmp/snmp_mibII/mibII.h')
-rw-r--r-- | contrib/bsnmp/snmp_mibII/mibII.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/contrib/bsnmp/snmp_mibII/mibII.h b/contrib/bsnmp/snmp_mibII/mibII.h index 8d50528..d47bc0b 100644 --- a/contrib/bsnmp/snmp_mibII/mibII.h +++ b/contrib/bsnmp/snmp_mibII/mibII.h @@ -57,6 +57,9 @@ #include "snmp_mibII.h" #include "mibII_tree.h" +/* maximum size of the interface alias */ +static const u_int MIBIF_ALIAS_SIZE = 64 + 1; + /* * Interface list and flags. */ @@ -77,6 +80,9 @@ struct mibif_private { uint64_t hc_opackets; uint64_t hc_imcasts; uint64_t hc_ipackets; + + /* this should be made public */ + char alias[MIBIF_ALIAS_SIZE]; }; #define MIBIF_PRIV(IFP) ((struct mibif_private *)((IFP)->private)) |