diff options
author | Lev Walkin <vlm@lionet.info> | 2005-03-29 17:21:14 +0000 |
---|---|---|
committer | Lev Walkin <vlm@lionet.info> | 2005-03-29 17:21:14 +0000 |
commit | fc7764376582dcc4602c36293d12d67f4184f199 (patch) | |
tree | 91f43ec4e13f644dc7ea04b699b534b23b53929a | |
parent | c23501183da7bc724357d570c3d9739b913616de (diff) |
globalized assert()
-rw-r--r-- | skeletons/ANY.c | 1 | ||||
-rw-r--r-- | skeletons/BMPString.c | 1 | ||||
-rw-r--r-- | skeletons/GeneralizedTime.c | 3 | ||||
-rw-r--r-- | skeletons/INTEGER.h | 5 | ||||
-rw-r--r-- | skeletons/NativeInteger.c | 3 | ||||
-rw-r--r-- | skeletons/NativeReal.c | 1 | ||||
-rw-r--r-- | skeletons/OBJECT_IDENTIFIER.c | 1 | ||||
-rw-r--r-- | skeletons/OCTET_STRING.c | 1 | ||||
-rw-r--r-- | skeletons/REAL.c | 1 | ||||
-rw-r--r-- | skeletons/RELATIVE-OID.c | 1 | ||||
-rw-r--r-- | skeletons/UTCTime.c | 1 | ||||
-rw-r--r-- | skeletons/UniversalString.c | 1 | ||||
-rw-r--r-- | skeletons/asn-decoder-template.c | 4 | ||||
-rw-r--r-- | skeletons/asn_codecs_prim.c | 1 | ||||
-rw-r--r-- | skeletons/asn_system.h | 3 | ||||
-rw-r--r-- | skeletons/ber_decoder.c | 1 | ||||
-rw-r--r-- | skeletons/constr_CHOICE.c | 1 | ||||
-rw-r--r-- | skeletons/constr_SEQUENCE.c | 1 | ||||
-rw-r--r-- | skeletons/constr_SET.c | 1 | ||||
-rw-r--r-- | skeletons/constr_SET_OF.c | 1 | ||||
-rw-r--r-- | skeletons/der_encoder.c | 1 | ||||
-rw-r--r-- | skeletons/xer_decoder.c | 8 |
22 files changed, 15 insertions, 27 deletions
diff --git a/skeletons/ANY.c b/skeletons/ANY.c index 54cc9a78..73702444 100644 --- a/skeletons/ANY.c +++ b/skeletons/ANY.c @@ -4,7 +4,6 @@ */ #include <asn_internal.h> #include <ANY.h> -#include <assert.h> #include <errno.h> static asn_OCTET_STRING_specifics_t asn_DEF_ANY_specs = { diff --git a/skeletons/BMPString.c b/skeletons/BMPString.c index 42b84f68..f3308bf7 100644 --- a/skeletons/BMPString.c +++ b/skeletons/BMPString.c @@ -5,7 +5,6 @@ #include <asn_internal.h> #include <BMPString.h> #include <UTF8String.h> -#include <assert.h> /* * BMPString basic type description. diff --git a/skeletons/GeneralizedTime.c b/skeletons/GeneralizedTime.c index 2a28d734..f52aec74 100644 --- a/skeletons/GeneralizedTime.c +++ b/skeletons/GeneralizedTime.c @@ -8,9 +8,6 @@ #include <GeneralizedTime.h> #include <time.h> #include <errno.h> -#ifndef __NO_ASSERT_H__ -#include <assert.h> -#endif /* __NO_ASSERT_H__ */ #if defined(WIN32) #warning PLEASE STOP AND READ! diff --git a/skeletons/INTEGER.h b/skeletons/INTEGER.h index dbc85257..416efd9a 100644 --- a/skeletons/INTEGER.h +++ b/skeletons/INTEGER.h @@ -47,4 +47,9 @@ xer_type_encoder_f INTEGER_encode_xer; int asn_INTEGER2long(const INTEGER_t *i, long *l); int asn_long2INTEGER(INTEGER_t *i, long l); +/* + * Convert the integer value into the corresponding enumeration map entry. + */ +const asn_INTEGER_enum_map_t *INTEGER_map_value2enum(asn_INTEGER_specifics_t *specs, long value); + #endif /* _INTEGER_H_ */ diff --git a/skeletons/NativeInteger.c b/skeletons/NativeInteger.c index acdbff6f..2b136185 100644 --- a/skeletons/NativeInteger.c +++ b/skeletons/NativeInteger.c @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2004 Lev Walkin <vlm@lionet.info>. All rights reserved. + * Copyright (c) 2004, 2005 Lev Walkin <vlm@lionet.info>. All rights reserved. * Redistribution and modifications are permitted subject to BSD license. */ /* @@ -11,7 +11,6 @@ */ #include <asn_internal.h> #include <NativeInteger.h> -#include <assert.h> /* * NativeInteger basic type description. diff --git a/skeletons/NativeReal.c b/skeletons/NativeReal.c index 5bc95b05..f2a3afce 100644 --- a/skeletons/NativeReal.c +++ b/skeletons/NativeReal.c @@ -12,7 +12,6 @@ #include <asn_internal.h> #include <NativeReal.h> #include <REAL.h> -#include <assert.h> /* * NativeReal basic type description. diff --git a/skeletons/OBJECT_IDENTIFIER.c b/skeletons/OBJECT_IDENTIFIER.c index f899ab08..7c9c980f 100644 --- a/skeletons/OBJECT_IDENTIFIER.c +++ b/skeletons/OBJECT_IDENTIFIER.c @@ -5,7 +5,6 @@ #include <asn_internal.h> #include <OBJECT_IDENTIFIER.h> #include <limits.h> /* for CHAR_BIT */ -#include <assert.h> #include <errno.h> /* diff --git a/skeletons/OCTET_STRING.c b/skeletons/OCTET_STRING.c index 207b5287..23118e33 100644 --- a/skeletons/OCTET_STRING.c +++ b/skeletons/OCTET_STRING.c @@ -5,7 +5,6 @@ #include <asn_internal.h> #include <OCTET_STRING.h> #include <BIT_STRING.h> /* for .bits_unused member */ -#include <assert.h> #include <errno.h> /* diff --git a/skeletons/REAL.c b/skeletons/REAL.c index 6a5e7cd9..92b42d2a 100644 --- a/skeletons/REAL.c +++ b/skeletons/REAL.c @@ -11,7 +11,6 @@ #include <stdlib.h> /* for strtod(3) */ #include <math.h> #include <errno.h> -#include <assert.h> #include <REAL.h> #undef INT_MAX diff --git a/skeletons/RELATIVE-OID.c b/skeletons/RELATIVE-OID.c index b0be6228..0c9235db 100644 --- a/skeletons/RELATIVE-OID.c +++ b/skeletons/RELATIVE-OID.c @@ -7,7 +7,6 @@ #include <RELATIVE-OID.h> #include <asn_codecs_prim.h> /* Encoder and decoder of a primitive type */ #include <limits.h> /* for CHAR_BIT */ -#include <assert.h> #include <errno.h> /* diff --git a/skeletons/UTCTime.c b/skeletons/UTCTime.c index f9de9dd3..e650b744 100644 --- a/skeletons/UTCTime.c +++ b/skeletons/UTCTime.c @@ -7,7 +7,6 @@ #include <GeneralizedTime.h> #include <time.h> #include <errno.h> -#include <assert.h> #ifndef __NO_ASN_TABLE__ diff --git a/skeletons/UniversalString.c b/skeletons/UniversalString.c index 27f1cda4..938bf07b 100644 --- a/skeletons/UniversalString.c +++ b/skeletons/UniversalString.c @@ -5,7 +5,6 @@ #include <asn_internal.h> #include <UniversalString.h> #include <UTF8String.h> -#include <assert.h> /* * UniversalString basic type description. diff --git a/skeletons/asn-decoder-template.c b/skeletons/asn-decoder-template.c index e4760756..4ff524c8 100644 --- a/skeletons/asn-decoder-template.c +++ b/skeletons/asn-decoder-template.c @@ -12,9 +12,9 @@ #include <sys/types.h> #include <unistd.h> /* for getopt */ #include <string.h> /* for strerror(3) */ -#include <errno.h> /* for errno */ -#include <assert.h> /* for assert(3) */ #include <sysexits.h> /* for EX_* exit codes */ +#include <assert.h> /* for assert(3) */ +#include <errno.h> /* for errno */ #include <asn_application.h> diff --git a/skeletons/asn_codecs_prim.c b/skeletons/asn_codecs_prim.c index afadb721..4c66f39a 100644 --- a/skeletons/asn_codecs_prim.c +++ b/skeletons/asn_codecs_prim.c @@ -4,7 +4,6 @@ */ #include <asn_internal.h> #include <asn_codecs_prim.h> -#include <assert.h> #include <errno.h> /* diff --git a/skeletons/asn_system.h b/skeletons/asn_system.h index 5a5eb9bf..2f4d7980 100644 --- a/skeletons/asn_system.h +++ b/skeletons/asn_system.h @@ -18,6 +18,9 @@ #include <sys/types.h> /* For size_t */ #include <stdarg.h> /* For va_start */ #include <stddef.h> /* for offsetof and ptrdiff_t */ +#ifndef __NO_ASSERT_H__ +#include <assert.h> /* for assert() macro */ +#endif #ifdef WIN32 diff --git a/skeletons/ber_decoder.c b/skeletons/ber_decoder.c index dc097fc5..bb7a0904 100644 --- a/skeletons/ber_decoder.c +++ b/skeletons/ber_decoder.c @@ -3,7 +3,6 @@ * Redistribution and modifications are permitted subject to BSD license. */ #include <asn_internal.h> -#include <assert.h> #undef ADVANCE #define ADVANCE(num_bytes) do { \ diff --git a/skeletons/constr_CHOICE.c b/skeletons/constr_CHOICE.c index bcf4c162..e49bc1af 100644 --- a/skeletons/constr_CHOICE.c +++ b/skeletons/constr_CHOICE.c @@ -5,7 +5,6 @@ */ #include <asn_internal.h> #include <constr_CHOICE.h> -#include <assert.h> /* * Number of bytes left for this structure. diff --git a/skeletons/constr_SEQUENCE.c b/skeletons/constr_SEQUENCE.c index d9526676..f5c33da8 100644 --- a/skeletons/constr_SEQUENCE.c +++ b/skeletons/constr_SEQUENCE.c @@ -5,7 +5,6 @@ */ #include <asn_internal.h> #include <constr_SEQUENCE.h> -#include <assert.h> /* * Number of bytes left for this structure. diff --git a/skeletons/constr_SET.c b/skeletons/constr_SET.c index 1b2f85f8..a45d7f9f 100644 --- a/skeletons/constr_SET.c +++ b/skeletons/constr_SET.c @@ -4,7 +4,6 @@ */ #include <asn_internal.h> #include <constr_SET.h> -#include <assert.h> /* for assert() */ #ifndef WIN32 #include <netinet/in.h> /* for ntohl() */ diff --git a/skeletons/constr_SET_OF.c b/skeletons/constr_SET_OF.c index 84892e78..1bae1f97 100644 --- a/skeletons/constr_SET_OF.c +++ b/skeletons/constr_SET_OF.c @@ -5,7 +5,6 @@ #include <asn_internal.h> #include <constr_SET_OF.h> #include <asn_SET_OF.h> -#include <assert.h> /* * Number of bytes left for this structure. diff --git a/skeletons/der_encoder.c b/skeletons/der_encoder.c index 62ad757e..68dd24e6 100644 --- a/skeletons/der_encoder.c +++ b/skeletons/der_encoder.c @@ -3,7 +3,6 @@ * Redistribution and modifications are permitted subject to BSD license. */ #include <asn_internal.h> -#include <assert.h> #include <errno.h> static ssize_t der_write_TL(ber_tlv_tag_t tag, ber_tlv_len_t len, diff --git a/skeletons/xer_decoder.c b/skeletons/xer_decoder.c index d0a08783..b112a72d 100644 --- a/skeletons/xer_decoder.c +++ b/skeletons/xer_decoder.c @@ -1,8 +1,10 @@ - +/* + * Copyright (c) 2004, 2005 Lev Walkin <vlm@lionet.info>. All rights reserved. + * Redistribution and modifications are permitted subject to BSD license. + */ #include <asn_application.h> #include <asn_internal.h> #include <xer_support.h> /* XER/XML parsing support */ -#include <assert.h> /* @@ -346,5 +348,3 @@ xer_skip_unknown(xer_check_tag_e tcv, ber_tlv_len_t *depth) { return -1; } } - - |