From d21c5058fc0695a439e72706a4a0bf02f4ed8044 Mon Sep 17 00:00:00 2001 From: Lev Walkin Date: Wed, 29 Sep 2004 13:18:09 +0000 Subject: [PATCH] different type name for the big integer --- libasn1parser/Makefile.in | 2 +- libasn1parser/asn1p_expr.h | 2 +- libasn1parser/asn1p_l.c | 6 +++--- libasn1parser/asn1p_oid.c | 4 ++-- libasn1parser/asn1p_oid.h | 4 ++-- libasn1parser/asn1p_value.c | 2 +- libasn1parser/asn1p_value.h | 4 ++-- libasn1parser/asn1p_y.c | 2 +- libasn1parser/asn1p_y.h | 2 +- libasn1parser/asn1parser.h | 2 +- 10 files changed, 15 insertions(+), 15 deletions(-) diff --git a/libasn1parser/Makefile.in b/libasn1parser/Makefile.in index cb9ebd03..dc7abe83 100644 --- a/libasn1parser/Makefile.in +++ b/libasn1parser/Makefile.in @@ -447,9 +447,9 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -rm -f asn1p_y.h -rm -f asn1p_l.c -rm -f asn1p_y.c - -rm -f asn1p_y.h clean: clean-am clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ diff --git a/libasn1parser/asn1p_expr.h b/libasn1parser/asn1p_expr.h index 4cdcd41f..05329e0c 100644 --- a/libasn1parser/asn1p_expr.h +++ b/libasn1parser/asn1p_expr.h @@ -170,7 +170,7 @@ typedef struct asn1p_expr_s { TM_IMPLICIT, TM_EXPLICIT, } tag_mode; - asn1_integer_t tag_value; + asn1c_integer_t tag_value; } tag; struct asn1p_expr_marker_s { diff --git a/libasn1parser/asn1p_l.c b/libasn1parser/asn1p_l.c index 2d0c3075..93a12c34 100644 --- a/libasn1parser/asn1p_l.c +++ b/libasn1parser/asn1p_l.c @@ -1808,7 +1808,7 @@ int asn1p_lexer_pedantic_1990 = 0; int asn1p_lexer_types_year = 0; int asn1p_lexer_constructs_year = 0; static int _check_dashes(char *ptr); -static asn1_integer_t asn1p_atoi(char *ptr); /* errno is either 0 or ERANGE */ +static asn1c_integer_t asn1p_atoi(char *ptr); /* errno is either 0 or ERANGE */ /* * Check that the type is defined in the year of the standard choosen. @@ -3957,9 +3957,9 @@ _check_dashes(char *ptr) { return 0; } -static asn1_integer_t +static asn1c_integer_t asn1p_atoi(char *ptr) { - asn1_integer_t value; + asn1c_integer_t value; errno = 0; /* Clear the error code */ if(sizeof(value) <= sizeof(int)) { diff --git a/libasn1parser/asn1p_oid.c b/libasn1parser/asn1p_oid.c index 2c22b0fd..deb8c381 100644 --- a/libasn1parser/asn1p_oid.c +++ b/libasn1parser/asn1p_oid.c @@ -39,7 +39,7 @@ asn1p_oid_free(asn1p_oid_t *oid) { } asn1p_oid_arc_t * -asn1p_oid_arc_new(const char *optName, asn1_integer_t optNumber /* = -1 */) { +asn1p_oid_arc_new(const char *optName, asn1c_integer_t optNumber /* = -1 */) { asn1p_oid_arc_t *arc; arc = calloc(1, sizeof *arc); @@ -66,7 +66,7 @@ asn1p_oid_compare(asn1p_oid_t *a, asn1p_oid_t *b) { int i; for(i = 0; ; i++) { - asn1_integer_t cmp; + asn1c_integer_t cmp; if(b->arcs_count > i) { if(a->arcs_count <= i) diff --git a/libasn1parser/asn1p_oid.h b/libasn1parser/asn1p_oid.h index cbb6b079..d561c52d 100644 --- a/libasn1parser/asn1p_oid.h +++ b/libasn1parser/asn1p_oid.h @@ -12,7 +12,7 @@ * Object identifier arc (one number in the hierarchy). */ typedef struct asn1p_oid_arc_s { - asn1_integer_t number; /* -1 if not yet defined */ + asn1c_integer_t number; /* -1 if not yet defined */ char *name; /* 0 if not defined */ } asn1p_oid_arc_t; @@ -21,7 +21,7 @@ typedef struct asn1p_oid_arc_s { * Arc constructor. */ asn1p_oid_arc_t *asn1p_oid_arc_new( - const char *optName, asn1_integer_t optNumber /* = -1 */); + const char *optName, asn1c_integer_t optNumber /* = -1 */); /* * Arc destructor. */ diff --git a/libasn1parser/asn1p_value.c b/libasn1parser/asn1p_value.c index b3824097..f6c8c491 100644 --- a/libasn1parser/asn1p_value.c +++ b/libasn1parser/asn1p_value.c @@ -99,7 +99,7 @@ asn1p_value_fromdouble(double d) { } asn1p_value_t * -asn1p_value_fromint(asn1_integer_t i) { +asn1p_value_fromint(asn1c_integer_t i) { asn1p_value_t *v = calloc(1, sizeof *v); if(v) { v->value.v_integer = i; diff --git a/libasn1parser/asn1p_value.h b/libasn1parser/asn1p_value.h index 5310b01f..fa622d7f 100644 --- a/libasn1parser/asn1p_value.h +++ b/libasn1parser/asn1p_value.h @@ -29,7 +29,7 @@ typedef struct asn1p_value_s { union { asn1p_ref_t *reference; - asn1_integer_t v_integer; + asn1c_integer_t v_integer; double v_double; /* * Binary bits vector. @@ -59,7 +59,7 @@ asn1p_value_t *asn1p_value_fromref(asn1p_ref_t *ref, int do_copy); asn1p_value_t *asn1p_value_frombits(uint8_t *bits, int size_in_bits, int dc); asn1p_value_t *asn1p_value_frombuf(char *buffer, int size, int do_copy); asn1p_value_t *asn1p_value_fromdouble(double); -asn1p_value_t *asn1p_value_fromint(asn1_integer_t); +asn1p_value_t *asn1p_value_fromint(asn1c_integer_t); asn1p_value_t *asn1p_value_clone(asn1p_value_t *); void asn1p_value_free(asn1p_value_t *); diff --git a/libasn1parser/asn1p_y.c b/libasn1parser/asn1p_y.c index 9d621e24..02d61810 100644 --- a/libasn1parser/asn1p_y.c +++ b/libasn1parser/asn1p_y.c @@ -184,7 +184,7 @@ typedef union { asn1p_paramlist_t *a_plist; /* A pargs list */ struct asn1p_expr_marker_s a_marker; /* OPTIONAL/DEFAULT */ enum asn1p_constr_pres_e a_pres; /* PRESENT/ABSENT/OPTIONAL */ - asn1_integer_t a_int; + asn1c_integer_t a_int; char *tv_str; struct { char *buf; diff --git a/libasn1parser/asn1p_y.h b/libasn1parser/asn1p_y.h index 788f2d9e..e1c581b1 100644 --- a/libasn1parser/asn1p_y.h +++ b/libasn1parser/asn1p_y.h @@ -19,7 +19,7 @@ typedef union { asn1p_paramlist_t *a_plist; /* A pargs list */ struct asn1p_expr_marker_s a_marker; /* OPTIONAL/DEFAULT */ enum asn1p_constr_pres_e a_pres; /* PRESENT/ABSENT/OPTIONAL */ - asn1_integer_t a_int; + asn1c_integer_t a_int; char *tv_str; struct { char *buf; diff --git a/libasn1parser/asn1parser.h b/libasn1parser/asn1parser.h index 126057d6..ff7e410d 100644 --- a/libasn1parser/asn1parser.h +++ b/libasn1parser/asn1parser.h @@ -29,7 +29,7 @@ * type is used by the compiler itself to handle large integer values * specified inside ASN.1 grammar. */ -typedef intmax_t asn1_integer_t; +typedef intmax_t asn1c_integer_t; #ifdef PRIdMAX #define PRIdASN PRIdMAX #define PRIuASN PRIuMAX