const


git-svn-id: https://asn1c.svn.sourceforge.net/svnroot/asn1c/trunk@4 59561ff5-6e30-0410-9f3c-9617f08c8826
diff --git a/libasn1compiler/asn1c_C.c b/libasn1compiler/asn1c_C.c
index 8ec476c..0f5cf2b 100644
--- a/libasn1compiler/asn1c_C.c
+++ b/libasn1compiler/asn1c_C.c
@@ -1364,7 +1364,7 @@
 		ACT_EL_VALUE);
 
 	if(size_present || value_present) {
-		OUT("%s_t *st = sptr;\n", MKID(arg->expr->Identifier));
+		OUT("const %s_t *st = sptr;\n", MKID(arg->expr->Identifier));
 		if(size_present) {
 			OUT("size_t size;\n");
 			OUT("size_t min_size __attribute__ ((unused)) = %ld;\n",
@@ -1848,7 +1848,7 @@
 
 	OUT("/* The underlying type is %s */\n",
 		ASN_EXPR_TYPE2STR(etype));
-	OUT("%s_t *st = sptr;\n", MKID(arg->expr->Identifier));
+	OUT("const %s_t *st = sptr;\n", MKID(arg->expr->Identifier));
 
 	switch(etype) {
 	case ASN_STRING_UTF8String: