ASN1_ARRAY_TYPE -> asn_static_node_t
authorNikos Mavrogiannopoulos <nmav@gnutls.org>
Mon, 1 Oct 2012 20:00:02 +0000 (22:00 +0200)
committerNikos Mavrogiannopoulos <nmav@gnutls.org>
Mon, 1 Oct 2012 20:14:09 +0000 (22:14 +0200)
lib/libtasn1.h
lib/structure.c

index 4c246e9..fc5c6d0 100644 (file)
@@ -118,13 +118,13 @@ extern "C"
   /*****************************************/
   /* For the on-disk format of ASN.1 trees */
   /*****************************************/
-  struct static_struct_asn
+  struct asn_static_node_st
   {
     const char *name;          /* Node name */
     unsigned int type;         /* Node type */
     const void *value;         /* Node value */
   };
-  typedef struct static_struct_asn ASN1_ARRAY_TYPE;
+  typedef struct asn_static_node_st asn_static_node_t;
 
 /* List of constants for field type of typedef node_asn  */
 #define ASN1_ETYPE_CONSTANT       1
@@ -183,7 +183,7 @@ extern "C"
                       const char *vectorName, char *errorDescription);
 
   extern ASN1_API int
-    asn1_array2tree (const ASN1_ARRAY_TYPE * array,
+    asn1_array2tree (const asn_static_node_t * array,
                     asn_node_t * definitions, char *errorDescription);
 
   extern ASN1_API void
@@ -305,6 +305,9 @@ extern "C"
 #define ASN1_TYPE node_asn_t
 #define ASN1_TYPE_EMPTY NULL
 
+#define static_struct_asn asn_static_node_st
+#define ASN1_ARRAY_TYPE asn_static_node_t
+
 #ifdef __cplusplus
 }
 #endif
index aa141bf..4ce9f6a 100644 (file)
@@ -96,7 +96,7 @@ _asn1_create_static_structure (asn_node_t pointer, char *output_file_name,
 
   fprintf (file, "#include <libtasn1.h>\n\n");
 
-  fprintf (file, "const ASN1_ARRAY_TYPE %s[] = {\n", vector_name);
+  fprintf (file, "const asn_static_node_t %s[] = {\n", vector_name);
 
   p = pointer;
 
@@ -174,7 +174,7 @@ _asn1_create_static_structure (asn_node_t pointer, char *output_file_name,
  *   %ASN1_ARRAY_ERROR if the array pointed by @array is wrong.
  **/
 int
-asn1_array2tree (const ASN1_ARRAY_TYPE * array, asn_node_t * definitions,
+asn1_array2tree (const asn_static_node_t * array, asn_node_t * definitions,
                 char *errorDescription)
 {
   asn_node_t p, p_last = NULL;