2 * Generated by asn1c-0.9.21 (http://lionet.info/asn1c)
3 * From ASN.1 module "RFC1213-MIB"
4 * found in "RFC1213-MIB.asn1"
5 * `asn1c -fskeletons-copy`
8 #include <asn_internal.h>
13 memb_udpLocalPort_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr,
14 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
18 _ASN_CTFAIL(app_key, td, sptr,
19 "%s: value not given (%s:%d)",
20 td->name, __FILE__, __LINE__);
24 value = *(const long *)sptr;
26 if((value >= 0 && value <= 65535)) {
27 /* Constraint check succeeded */
30 _ASN_CTFAIL(app_key, td, sptr,
31 "%s: constraint failed (%s:%d)",
32 td->name, __FILE__, __LINE__);
37 static asn_TYPE_member_t asn_MBR_UdpEntry_1[] = {
38 { ATF_NOFLAGS, 0, offsetof(struct UdpEntry, udpLocalAddress),
39 (ASN_TAG_CLASS_APPLICATION | (0 << 2)),
42 0, /* Defer constraints checking to the member type */
43 0, /* PER is not compiled, use -gen-PER */
47 { ATF_NOFLAGS, 0, offsetof(struct UdpEntry, udpLocalPort),
48 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
50 &asn_DEF_NativeInteger,
51 memb_udpLocalPort_constraint_1,
52 0, /* PER is not compiled, use -gen-PER */
57 static ber_tlv_tag_t asn_DEF_UdpEntry_tags_1[] = {
58 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
60 static asn_TYPE_tag2member_t asn_MAP_UdpEntry_tag2el_1[] = {
61 { (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 1, 0, 0 }, /* udpLocalPort at 253 */
62 { (ASN_TAG_CLASS_APPLICATION | (0 << 2)), 0, 0, 0 } /* udpLocalAddress at 251 */
64 static asn_SEQUENCE_specifics_t asn_SPC_UdpEntry_specs_1 = {
65 sizeof(struct UdpEntry),
66 offsetof(struct UdpEntry, _asn_ctx),
67 asn_MAP_UdpEntry_tag2el_1,
68 2, /* Count of tags in the map */
69 0, 0, 0, /* Optional elements (not needed) */
70 -1, /* Start extensions */
71 -1 /* Stop extensions */
73 asn_TYPE_descriptor_t asn_DEF_UdpEntry = {
83 0, 0, /* No PER support, use "-gen-PER" to enable */
84 0, /* Use generic outmost tag fetcher */
85 asn_DEF_UdpEntry_tags_1,
86 sizeof(asn_DEF_UdpEntry_tags_1)
87 /sizeof(asn_DEF_UdpEntry_tags_1[0]), /* 1 */
88 asn_DEF_UdpEntry_tags_1, /* Same as above */
89 sizeof(asn_DEF_UdpEntry_tags_1)
90 /sizeof(asn_DEF_UdpEntry_tags_1[0]), /* 1 */
91 0, /* No PER visible constraints */
93 2, /* Elements count */
94 &asn_SPC_UdpEntry_specs_1 /* Additional specs */