diff options
author | Gerald Combs <gerald@wireshark.org> | 2006-02-17 16:35:45 +0000 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2006-02-17 16:35:45 +0000 |
commit | d3f60e495be814268d57661042e60c73bb36c13f (patch) | |
tree | 1855a3bfcdccb2e1e4d8a16e3ea05c92c6c353bc /asn1 | |
parent | 0b2d1add6f8fedefc984930349b059dc8a0bc3b2 (diff) |
Don't try to fill in last_dn if it doesn't exist. Fixes the current Buildbot
failure.
svn path=/trunk/; revision=17337
Diffstat (limited to 'asn1')
-rw-r--r-- | asn1/x509if/x509if.cnf | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/asn1/x509if/x509if.cnf b/asn1/x509if/x509if.cnf index 1cd9bb1552..2452c0cb28 100644 --- a/asn1/x509if/x509if.cnf +++ b/asn1/x509if/x509if.cnf @@ -202,13 +202,16 @@ DistinguishedName B "2.5.4.49" "id-at-distinguishedName" proto_item_append_text(top_of_rdn, " (%%s)", last_rdn); /* now append this to the DN */ - if(*last_dn) { - temp_dn = ep_alloc(MAX_DN_STR_LEN); /* is there a better way to use ep_alloc here ? */ - g_snprintf(temp_dn, MAX_DN_STR_LEN, "%%s,%%s", last_rdn, last_dn); - last_dn[0] = '\0'; - g_strlcat(last_dn, temp_dn, MAX_DN_STR_LEN); - } else - g_strlcat(last_dn, last_rdn, MAX_DN_STR_LEN); + if (last_dn) { + if(*last_dn) { + temp_dn = ep_alloc(MAX_DN_STR_LEN); /* is there a better way to use ep_alloc here ? */ + g_snprintf(temp_dn, MAX_DN_STR_LEN, "%%s,%%s", last_rdn, last_dn); + last_dn[0] = '\0'; + g_strlcat(last_dn, temp_dn, MAX_DN_STR_LEN); + } else { + g_strlcat(last_dn, last_rdn, MAX_DN_STR_LEN); + } + } doing_dn = FALSE; last_rdn = NULL; /* it will get freed when the next packet is dissected */ |