projects
/
oweals
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b61a87b
)
PR: 2091
author
Dr. Stephen Henson
<steve@openssl.org>
Tue, 10 Nov 2009 01:00:37 +0000
(
01:00
+0000)
committer
Dr. Stephen Henson
<steve@openssl.org>
Tue, 10 Nov 2009 01:00:37 +0000
(
01:00
+0000)
Submitted by: Martin Kaiser <lists@kaiser.cx>, Stephen Henson
Approved by: steve@openssl.org
If an OID has no short name or long name return the numerical representation.
crypto/objects/obj_dat.c
patch
|
blob
|
history
diff --git
a/crypto/objects/obj_dat.c
b/crypto/objects/obj_dat.c
index 7fd74332417b9e28a257ed5e8df4a2da9d5108e2..760af16dd9a7481bbf1ee3eb86af78ca2e151434 100644
(file)
--- a/
crypto/objects/obj_dat.c
+++ b/
crypto/objects/obj_dat.c
@@
-456,10
+456,13
@@
int OBJ_obj2txt(char *buf, int buf_len, const ASN1_OBJECT *a, int no_name)
s=OBJ_nid2ln(nid);
if (s == NULL)
s=OBJ_nid2sn(nid);
- if (buf)
- BUF_strlcpy(buf,s,buf_len);
- n=strlen(s);
- return n;
+ if (s)
+ {
+ if (buf)
+ BUF_strlcpy(buf,s,buf_len);
+ n=strlen(s);
+ return n;
+ }
}