summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorSimon Josefsson <simon@josefsson.org>2006-03-08 17:46:36 +0000
committerSimon Josefsson <simon@josefsson.org>2006-03-08 17:46:36 +0000
commit35b058b153a9bd8e93ac6dcbfe0e4716b20f68fa (patch)
tree1feaf25cdae8be3a2a613a1585ed65ea0d5c1201 /lib
parentbff6d8dfbcf818348b32e0a0e00e1134dc82b6fa (diff)
downloadgnutls-35b058b153a9bd8e93ac6dcbfe0e4716b20f68fa.tar.gz
Update.
Diffstat (limited to 'lib')
-rw-r--r--lib/minitasn1/coding.c4
-rw-r--r--lib/minitasn1/libtasn1.h10
2 files changed, 9 insertions, 5 deletions
diff --git a/lib/minitasn1/coding.c b/lib/minitasn1/coding.c
index 4be3a2f237..272720be4c 100644
--- a/lib/minitasn1/coding.c
+++ b/lib/minitasn1/coding.c
@@ -67,7 +67,7 @@ _asn1_error_description_value_not_found(node_asn *node,char *ErrorDescription)
* The @ans buffer is pre-allocated and must have room for the output.
**/
void
-asn1_length_der(unsigned long len, unsigned char *ans, int *ans_len)
+asn1_length_der(unsigned long int len, unsigned char *ans, int *ans_len)
{
int k;
unsigned char temp[SIZEOF_UNSIGNED_LONG_INT];
@@ -87,7 +87,7 @@ asn1_length_der(unsigned long len, unsigned char *ans, int *ans_len)
*ans_len=k+1;
if(ans!=NULL){
ans[0]=((unsigned char)k&0x7F)+128;
- while(k--) ans[*ans_len-1-k]=temp[k];
+ while(k--) ans[*ans_len-1-k]=temp[k];
}
}
}
diff --git a/lib/minitasn1/libtasn1.h b/lib/minitasn1/libtasn1.h
index 848014f316..1ffb50b7d6 100644
--- a/lib/minitasn1/libtasn1.h
+++ b/lib/minitasn1/libtasn1.h
@@ -104,7 +104,8 @@ extern "C"
/* Structure definition used for the node of the tree */
/* that represent an ASN.1 DEFINITION. */
/******************************************************/
- typedef struct node_asn_struct
+
+ struct node_asn_struct
{
char *name; /* Node name */
unsigned int type; /* Node type */
@@ -113,7 +114,9 @@ extern "C"
struct node_asn_struct *down; /* Pointer to the son node */
struct node_asn_struct *right; /* Pointer to the brother node */
struct node_asn_struct *left; /* Pointer to the next list element */
- } node_asn;
+ };
+
+ typedef struct node_asn_struct node_asn;
typedef node_asn *ASN1_TYPE;
@@ -226,7 +229,8 @@ extern "C"
signed long asn1_get_length_der (const unsigned char *der, int der_len,
int *len);
- void asn1_length_der (unsigned long len, unsigned char *ans, int *ans_len);
+ void asn1_length_der (unsigned long int len, unsigned char *ans,
+ int *ans_len);
/* Other utility functions. */