Don't try and construct an OID string if the len is zero. Fixes
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9246 svn path=/trunk/; revision=52455
This commit is contained in:
parent
0863791253
commit
69da562c83
|
@ -832,11 +832,14 @@ const char* oid_subid2string(guint32* subids, guint len) {
|
|||
return rel_oid_subid2string(subids, len, TRUE);
|
||||
}
|
||||
const char* rel_oid_subid2string(guint32* subids, guint len, gboolean is_absolute) {
|
||||
char* s = (char *)ep_alloc0(((len)*11)+1);
|
||||
char* w = s;
|
||||
char *s, *w;
|
||||
|
||||
if(!subids)
|
||||
if(!subids || len == 0)
|
||||
return "*** Empty OID ***";
|
||||
|
||||
s = (char *)ep_alloc0(((len)*11)+2);
|
||||
w = s;
|
||||
|
||||
if (!is_absolute)
|
||||
*w++ = '.';
|
||||
|
||||
|
|
Loading…
Reference in New Issue