From 27d7260075ba525c69e5b8e8ccb1b98010b56dd3 Mon Sep 17 00:00:00 2001 From: Richard Levitte Date: Sat, 8 Jul 2000 07:56:12 +0000 Subject: Corrected small bug that could add ',L' when it shouldn't --- crypto/objects/objects.pl | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'crypto/objects/objects.pl') diff --git a/crypto/objects/objects.pl b/crypto/objects/objects.pl index 04fcdec207..c956bbb841 100644 --- a/crypto/objects/objects.pl +++ b/crypto/objects/objects.pl @@ -203,11 +203,22 @@ sub process_oid @a = split(/\s+/,$myoid); $pref_oid = ""; + $pref_sep = ""; if (!($a[0] =~ /^[0-9]+$/)) { $a[0] =~ s/-/_/g; - $pref_oid = "OBJ_" . $a[0] . ','; + $pref_oid = "OBJ_" . $a[0]; + $pref_sep = ","; shift @a; } - return($pref_oid . join('L,',@a) . 'L'); + $oids = join('L,',@a) . "L"; + if ($oids ne "L") + { + $oids = $pref_oid . $pref_sep . $oids; + } + else + { + $oids = $pref_oid; + } + return($oids); } -- cgit v1.2.3