Changeset 17512

Show
Ignore:
Timestamp:
09.10.2008 14:44:09 (11 years ago)
Author:
kjdon
Message:

added a method to turn windows filename paths (with single back slash) into a form suitable for use in a regular expression (with double backslash)

Files:
1 modified

Legend:

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

    r17204 r17512  
    594594} 
    595595 
     596sub filename_to_regex { 
     597    my $filename = shift (@_); 
     598 
     599    # need to put single backslash back to double so that regex works 
     600    if ($ENV{'GSDLOS'} =~ /^windows$/i) { 
     601    $filename =~ s/\\/\\\\/g; 
     602    } 
     603    return $filename; 
     604} 
    596605 
    597606sub filename_cat {