John E. Malmberg [Wed, 29 Oct 2008 22:02:43 +0000 (17:02 -0500)]
From: "John E. Malmberg" <wb8tyw@qsl.net>
Message-id: <
490923D3.90407@qsl.net>
Remove trailing dot when efs_charset is in effect.
p4raw-id: //depot/perl@34666
*cp2 = '\0';
if (do_tovmsspec(resspec,cp,0,NULL)) {
s = vmsspec;
+
+ /* When a UNIX spec with no file type is translated to VMS, */
+ /* A trailing '.' is appended under ODS-5 rules. */
+ /* Here we do not want that trailing "." as it prevents */
+ /* Looking for a implied ".exe" type. */
+ if (decc_efs_charset) {
+ int i;
+ i = strlen(vmsspec);
+ if (vmsspec[i-1] == '.') {
+ vmsspec[i-1] = '\0';
+ }
+ }
+
if (*rest) {
for (cp2 = vmsspec + strlen(vmsspec);
*rest && cp2 - vmsspec < sizeof vmsspec;