2 more vms.c fix-ups and status
authorCraig A. Berry <craigberry@mac.com>
Fri, 1 Sep 2000 01:47:22 +0000 (20:47 -0500)
committerJarkko Hietaniemi <jhi@iki.fi>
Fri, 1 Sep 2000 13:43:18 +0000 (13:43 +0000)
Message-Id: <4.3.2.7.2.20000901011206.01ca2e88@exchi01>

p4raw-id: //depot/perl@6965

pod/perldelta.pod
vms/vms.c

index d739204..a903e78 100644 (file)
@@ -754,11 +754,6 @@ one can (or, if one can, whether it's a good idea) link together at
 all binaries with different ideas about file offsets, all this is
 platform-dependent.
 
-=head2 ftmp-posix subtest 6 fails in VMS
-
-The test exposes a flushing bug in the VMS port of Perl, this failure
-as such can be ignored.
-
 =head2 ftmp-security tests warn 'system possibly insecure'
 
 Don't panic.  Read INSTALL 'make test' section instead. 
@@ -766,10 +761,13 @@ Don't panic.  Read INSTALL 'make test' section instead.
 =head2 Long Doubles Still Don't Work In Solaris
 
 The experimental long double support is still very much so in Solaris.
-(Other platforms like Linux and Tru64 are beginning to solidify in this area.)
+(Other platforms like Linux and Tru64 are beginning to solidify in
+this area.)
 
 =head2 Storable tests fail in some platforms
 
+If any Storable tests fail the use of Storable is not advisable.
+
 =over 4
 
 =item *
@@ -791,6 +789,10 @@ st-06compat fails in UNICOS and UNICOS/mk.
 This means that you cannot read old (pre-Storable-0.7) Storable images
 made in other platforms.
 
+=item *
+
+st-store.t and st-retrieve may fail with Compaq C 6.2 on OpenVMS Alpha 7.2.
+
 =back
 
 =head1 Reporting Bugs
index dc14c5f..8e56d30 100644 (file)
--- a/vms/vms.c
+++ b/vms/vms.c
@@ -1,9 +1,12 @@
 /* vms.c
  *
  * VMS-specific routines for perl5
+ * Version: 5.7.0
  *
- * Last revised: 20-Aug-1999 by Charles Bailey  bailey@newman.upenn.edu
- * Version: 5.5.60
+ * August 2000 tweaks to vms_image_init, my_flush, my_fwrite, cando_by_name, 
+ *             and Perl_cando by Craig Berry
+ * 29-Aug-2000 Charles Lane's piping improvements rolled in
+ * 20-Aug-1999 revisions by Charles Bailey  bailey@newman.upenn.edu
  */
 
 #include <acedef.h>
@@ -4726,6 +4729,13 @@ my_flush(FILE *fp)
 #endif
            res = fsync(fileno(fp));
     }
+/*
+ * If the flush succeeded but set end-of-file, we need to clear
+ * the error because our caller may check ferror().  BTW, this 
+ * probably means we just flushed an empty file.
+ */
+    if (res == 0 && vaxc$errno == RMS$_EOF) clearerr(fp);
+
     return res;
 }
 /*}}}*/
@@ -5587,7 +5597,16 @@ Perl_cando(pTHX_ Mode_t bit, Uid_t effective, Stat_t *statbufp)
                              &namdsc,&namdsc.dsc$w_length,0,0);
     if (retsts & 1) {
       fname[namdsc.dsc$w_length] = '\0';
-      return cando_by_name(bit,effective,fname);
+/* 
+ * lib$fid_to_name returns DVI$_LOGVOLNAM as the device part of the name,
+ * but if someone has redefined that logical, Perl gets very lost.  Since
+ * we have the physical device name from the stat buffer, just paste it on.
+ */
+      char fname_phdev[NAM$C_MAXRSS+1];
+      strcpy( fname_phdev, statbufp->st_devnam );
+      strcat( fname_phdev, strrchr(fname, ':') );
+
+      return cando_by_name(bit,effective,fname_phdev);
     }
     else if (retsts == SS$_NOSUCHDEV || retsts == SS$_NOSUCHFILE) {
       Perl_warn(aTHX_ "Can't get filespec - stale stat buffer?\n");