Changeset 17057


Ignore:
Timestamp:
2008-08-28T13:29:45+12:00 (16 years ago)
Author:
kjdon
Message:

added some more warnings when tidying up assigned OIDs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gsdl/trunk/perllib/doc.pm

    r17025 r17057  
    283283   
    284284    my $use_hash_oid = 0;
    285     # if an OID wasn't provided claculate one
     285    # if an OID wasn't provided calculate one
    286286    if (!defined $OID) {
    287287    $OID = "NULL";
     
    313313        if (defined $identifier && $identifier ne "") {
    314314        $OID = $identifier;
    315         $OID =~ s/\.//; #remove any periods
     315        if ($OID =~ /\./) {
     316            print STDERR "Warning, assigned identifier $identifier contains periods (.), removing them\n";
     317            $OID =~ s/\.//g; #remove any periods
     318        }
     319        if ($OID =~ /^\d*$/) {
     320            print STDERR "Warning, assigned identifier $identifier contains only digits. Prepending 'D'.\n";
     321            $OID = "D" . $OID;
     322        }
    316323        if ($OID =~ /^[\d]*$/) {
    317324            $OID = "D" . $OID;
Note: See TracChangeset for help on using the changeset viewer.