From: Craig A. Berry Date: Thu, 18 Jun 2009 02:23:49 +0000 (-0500) Subject: Handle the rare but legal angle bracket in unixify. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=5ad5b34cb2af84d4f37219a5dee752fca0459151;p=p5sagit%2Fp5-mst-13.2.git Handle the rare but legal angle bracket in unixify. We have been getting: $ perl -e "print VMS::Filespec::unixify('foo:');" /foo/');" /foo/bar/ --- diff --git a/vms/ext/filespec.t b/vms/ext/filespec.t index 5dd27c9..b40cc81 100644 --- a/vms/ext/filespec.t +++ b/vms/ext/filespec.t @@ -83,6 +83,7 @@ __DATA__ # Basic VMS to Unix filespecs __some_:[__where_.__over_]__the_.__rainbow_ unixify /__some_/__where_/__over_/__the_.__rainbow_ ^ +__some_:<__where_.__over_>__the_.__rainbow_ unixify /__some_/__where_/__over_/__the_.__rainbow_ ^ [.__some_.__where_.__over_]__the_.__rainbow_ unixify __some_/__where_/__over_/__the_.__rainbow_ ^ [-.__some_.__where_.__over_]__the_.__rainbow_ unixify ../__some_/__where_/__over_/__the_.__rainbow_ ^ [.__some_.--.__where_.__over_]__the_.__rainbow_ unixify __some_/../../__where_/__over_/__the_.__rainbow_ ^ diff --git a/vms/vms.c b/vms/vms.c index 0896934..9e94935 100644 --- a/vms/vms.c +++ b/vms/vms.c @@ -7346,7 +7346,7 @@ static char *int_tounixspec(const char *spec, char *rslt, int * utf8_fl) } if (*cp2 == ':') { *(cp1++) = '/'; - if (*(cp2+1) == '[') cp2++; + if (*(cp2+1) == '[' || *(cp2+1) == '<') cp2++; } else if (*cp2 == ']' || *cp2 == '>') { if (*(cp1-1) != '/') *(cp1++) = '/'; /* Don't double after ellipsis */