diff options
author | Simon Josefsson <simon@josefsson.org> | 2008-11-17 19:03:30 +0100 |
---|---|---|
committer | Simon Josefsson <simon@josefsson.org> | 2008-11-17 19:03:30 +0100 |
commit | 7a345f9026677dc52241d93e2d1180f9436b07ab (patch) | |
tree | cb996f282a5602efcd7b60e1073f488b92d59c1c /lib | |
parent | 563a142600a37252a295a1b7cbbca5b59c438950 (diff) | |
download | libtasn1-7a345f9026677dc52241d93e2d1180f9436b07ab.tar.gz libtasn1-7a345f9026677dc52241d93e2d1180f9436b07ab.tar.bz2 libtasn1-7a345f9026677dc52241d93e2d1180f9436b07ab.zip |
Fix more warnings.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ASN1.c | 4 | ||||
-rw-r--r-- | lib/ASN1.y | 4 | ||||
-rw-r--r-- | lib/element.c | 2 | ||||
-rw-r--r-- | lib/errors.c | 2 | ||||
-rw-r--r-- | lib/gstr.c | 3 | ||||
-rw-r--r-- | lib/int.h | 11 |
6 files changed, 9 insertions, 17 deletions
@@ -181,7 +181,7 @@ static char lastToken[ASN1_MAX_NAME_SIZE+1]; /* last token find in the file extern char _asn1_identifierMissing[]; static const char *fileName; /* file to parse */ -static int _asn1_yyerror (char *); +static int _asn1_yyerror (const char *); static int _asn1_yylex(void); @@ -2739,7 +2739,7 @@ int asn1_parser2array(const char *inputFileName,const char *outputFileName, /* Return: int */ /* */ /*************************************************************/ -static int _asn1_yyerror (char *s) +static int _asn1_yyerror (const char *s) { /* Sends the error description to the std_out */ @@ -51,7 +51,7 @@ static char lastToken[ASN1_MAX_NAME_SIZE+1]; /* last token find in the file extern char _asn1_identifierMissing[]; static const char *fileName; /* file to parse */ -static int _asn1_yyerror (char *); +static int _asn1_yyerror (const char *); static int _asn1_yylex(void); %} @@ -787,7 +787,7 @@ int asn1_parser2array(const char *inputFileName,const char *outputFileName, /* Return: int */ /* */ /*************************************************************/ -static int _asn1_yyerror (char *s) +static int _asn1_yyerror (const char *s) { /* Sends the error description to the std_out */ diff --git a/lib/element.c b/lib/element.c index 05da2f2..e82807f 100644 --- a/lib/element.c +++ b/lib/element.c @@ -33,6 +33,8 @@ #include <gstr.h> #include "structure.h" +#include "element.h" + void _asn1_hierarchical_name (ASN1_TYPE node, char *name, int name_size) { diff --git a/lib/errors.c b/lib/errors.c index 29e08dc..9524fe1 100644 --- a/lib/errors.c +++ b/lib/errors.c @@ -54,7 +54,7 @@ static const libtasn1_error_entry error_algorithms[] = { LIBTASN1_ERROR_ENTRY (ASN1_NAME_TOO_LONG), LIBTASN1_ERROR_ENTRY (ASN1_ARRAY_ERROR), LIBTASN1_ERROR_ENTRY (ASN1_ELEMENT_NOT_EMPTY), - {0} + {0, 0} }; /** @@ -1,5 +1,5 @@ /* - * Copyright (C) 2006 Free Software Foundation + * Copyright (C) 2006, 2008 Free Software Foundation * Copyright (C) 2002 Nikos Mavroyanopoulos * * This file is part of LIBTASN1. @@ -21,6 +21,7 @@ */ #include <int.h> +#include "gstr.h" /* These function are like strcat, strcpy. They only * do bounds checking (they shouldn't cause buffer overruns), @@ -140,15 +140,4 @@ struct node_asn #define CONST_DOWN (1<<29) #define CONST_RIGHT (1<<30) -/* Prototypes for gstr.c. */ -void _asn1_str_cat (char *dest, size_t dest_tot_size, const char *src); -void _asn1_str_cpy (char *dest, size_t dest_tot_size, const char *src); - -/* Prototypes for element.c. */ -void _asn1_hierarchical_name (ASN1_TYPE node, char *name, int name_size); -asn1_retCode _asn1_convert_integer (const char *value, - unsigned char *value_out, - int value_out_size, int *len); -int _asn1_append_sequence_set (ASN1_TYPE node); - #endif /* INT_H */ |