summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2013-11-05 23:17:47 +0100
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2013-11-05 23:17:55 +0100
commit72d25022f6f43b03da87109cd785b5cf7fbc0f4c (patch)
tree84f415f8565cd95416497e990a9269b9b97e7c7c /lib
parent85771be8181c6f9da9beec432d5637b6b4736161 (diff)
downloadgnutls-72d25022f6f43b03da87109cd785b5cf7fbc0f4c.tar.gz
bug fix in gnutls_x509_crt_set_dn() at DN parsing.
Diffstat (limited to 'lib')
-rw-r--r--lib/x509/x509_dn.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/x509/x509_dn.c b/lib/x509/x509_dn.c
index 31d83b69ee..384ad87422 100644
--- a/lib/x509/x509_dn.c
+++ b/lib/x509/x509_dn.c
@@ -132,7 +132,7 @@ gnutls_datum_t name, val;
if (crt == NULL || dn == NULL)
return gnutls_assert_val(GNUTLS_E_INVALID_REQUEST);
-
+
/* For each element */
while (*p != 0 && *p != '\n')
{
@@ -156,7 +156,8 @@ gnutls_datum_t name, val;
if (*p != ',' && *p != 0 && *p != '\n')
return gnutls_assert_val(GNUTLS_E_PARSING_ERROR);
- p++;
+ if (*p == ',')
+ p++;
}
return 0;