diff options
author | Martijn van Duren <martijn@cvs.openbsd.org> | 2023-11-04 09:22:53 +0000 |
---|---|---|
committer | Martijn van Duren <martijn@cvs.openbsd.org> | 2023-11-04 09:22:53 +0000 |
commit | 14fd307f1d2615b853dd90bb78c4610f1bee4afa (patch) | |
tree | 27040257dc2810a71aeb27c0bcd9978bb7ec60bc /usr.sbin/snmpd/snmpd.h | |
parent | a9322055e6a1c6446299656dfb9a426160dac1f7 (diff) |
Introduce application_internal.c. This backend is meant to replace
application_legacy.c, mps.c, and mib.c. This commit just introduces the
backend. The existing MIBs inside mib.c will be copied over in
subsequent commits.
OK tb@
Diffstat (limited to 'usr.sbin/snmpd/snmpd.h')
-rw-r--r-- | usr.sbin/snmpd/snmpd.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/snmpd/snmpd.h b/usr.sbin/snmpd/snmpd.h index 7abeeea0adf..3c46a451b1e 100644 --- a/usr.sbin/snmpd/snmpd.h +++ b/usr.sbin/snmpd/snmpd.h @@ -1,4 +1,4 @@ -/* $OpenBSD: snmpd.h,v 1.106 2022/10/06 14:41:08 martijn Exp $ */ +/* $OpenBSD: snmpd.h,v 1.107 2023/11/04 09:22:52 martijn Exp $ */ /* * Copyright (c) 2007, 2008, 2012 Reyk Floeter <reyk@openbsd.org> @@ -215,7 +215,8 @@ struct oid { (((_oid)->o_flags & OID_IFSET) && \ ((_oid)->o_data == NULL) && ((_oid)->o_val == 0)) -#define OID(...) { { __VA_ARGS__ } } +#define OID(...) (struct ber_oid){ { __VA_ARGS__ }, \ + (sizeof((uint32_t []) { __VA_ARGS__ }) / sizeof(uint32_t)) } #define MIBDECL(...) { { MIB_##__VA_ARGS__ } }, #__VA_ARGS__ #define MIB(...) { { MIB_##__VA_ARGS__ } }, NULL #define MIBEND { { 0 } }, NULL |