Changeset 19616 for gsdl/trunk
- Timestamp:
- 2009-05-27T13:52:35+12:00 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
gsdl/trunk/perllib/util.pm
r19056 r19616 635 635 } 636 636 637 637 sub tidy_up_oid { 638 my ($OID) = @_; 639 if ($OID =~ /\./) { 640 print STDERR "Warning, identifier $OID contains periods (.), removing them\n"; 641 $OID =~ s/\.//g; #remove any periods 642 } 643 if ($OID =~ /^\s.*\s$/) { 644 print STDERR "Warning, identifier $OID starts or ends with whitespace. Removing it\n"; 645 # remove starting and trailing whitespace 646 $OID =~ s/^\s+//; 647 $OID =~ s/\s+$//; 648 } 649 if ($OID =~ /^[\d]*$/) { 650 print STDERR "Warning, identifier $OID contains only digits. Prepending 'D'.\n"; 651 $OID = "D" . $OID; 652 } 653 654 return $OID; 655 } 638 656 sub envvar_prepend { 639 657 my ($var,$val) = @_;
Note:
See TracChangeset
for help on using the changeset viewer.