/* ASN1_STRING_set() allocated 'len + 1' bytes. */
newlen = t->length + 2 + 1;
str = (char *)ret->data;
- i = snprintf(str, newlen, "%s%s", (t->data >= '5') ? "19" : "20",
+ i = snprintf(str, newlen, "%s%s", (t->data[0] >= '5') ? "19" : "20",
(char *) t->data);
if (i == -1 || i >= newlen) {
ASN1_STRING_free(ret);
/* ASN1_STRING_set() allocated 'len + 1' bytes. */
newlen = t->length + 2 + 1;
str = (char *)ret->data;
- i = snprintf(str, newlen, "%s%s", (t->data >= '5') ? "19" : "20",
+ i = snprintf(str, newlen, "%s%s", (t->data[0] >= '5') ? "19" : "20",
(char *) t->data);
if (i == -1 || i >= newlen) {
ASN1_STRING_free(ret);