Various const fixes
diff --git a/programs/util/pem2der.c b/programs/util/pem2der.c
index 9364356..f372684 100644
--- a/programs/util/pem2der.c
+++ b/programs/util/pem2der.c
@@ -50,8 +50,8 @@
*/
struct options
{
- char *filename; /* filename of the input file */
- char *output_file; /* where to store the output */
+ const char *filename; /* filename of the input file */
+ const char *output_file; /* where to store the output */
} opt;
int convert_pem_to_der( const unsigned char *input, size_t ilen,
@@ -61,11 +61,11 @@
const unsigned char *s1, *s2, *end = input + ilen;
size_t len = 0;
- s1 = (unsigned char *) strstr( (char *) input, "-----BEGIN" );
+ s1 = (unsigned char *) strstr( (const char *) input, "-----BEGIN" );
if( s1 == NULL )
return( -1 );
- s2 = (unsigned char *) strstr( (char *) input, "-----END" );
+ s2 = (unsigned char *) strstr( (const char *) input, "-----END" );
if( s2 == NULL )
return( -1 );