Alter `OS_tty_read_char' under unix so that it echoes the input if the
authorChris Hanson <org/chris-hanson/cph>
Fri, 18 Dec 1987 00:03:51 +0000 (00:03 +0000)
committerChris Hanson <org/chris-hanson/cph>
Fri, 18 Dec 1987 00:03:51 +0000 (00:03 +0000)
standard input is a file.

v7/src/microcode/pruxfs.c
v7/src/microcode/version.h
v8/src/microcode/version.h

index 6f3fe8c1ff3e9cef395b68c200eaac6c25ec5d80..02f362496f7594777e359e4c383faeb6a60a2627 100644 (file)
@@ -1,6 +1,6 @@
 /* -*-C-*-
 
-$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/pruxfs.c,v 9.24 1987/11/23 06:46:36 cph Exp $
+$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/pruxfs.c,v 9.25 1987/12/18 00:03:51 cph Rel $
 
 Copyright (c) 1987 Massachusetts Institute of Technology
 
@@ -246,69 +246,18 @@ filemodestring (s, a)
    struct stat *s;
    char *a;
 {
-  static char ftypelet ();
-  static void rwx (), setst ();
+  extern char file_type_letter ();
+  extern void rwx (), setst ();
 
-  a[0] = ftypelet (s);
+  (a [0]) = (file_type_letter (s));
   /* Aren't there symbolic names for these byte-fields? */
-  rwx ((s->st_mode & 0700) << 0, &(a[1]));
-  rwx ((s->st_mode & 0070) << 3, &(a[4]));
-  rwx ((s->st_mode & 0007) << 6, &(a[7]));
-  setst (s->st_mode, a);
+  rwx (((s -> st_mode) & 0700) << 0, (& (a [1])));
+  rwx (((s -> st_mode) & 0070) << 3, (& (a [4])));
+  rwx (((s -> st_mode) & 0007) << 6, (& (a [7])));
+  setst ((s -> st_mode), a);
   return;
 }
 \f
-/* ftypelet - file type letter
-
-   Ftypelet accepts a file status block and returns a character code
-   describing the type of the file.  'd' is returned for directories,
-   'b' for block special files, 'c' for character special files, 'm'
-   for multiplexor files, 'l' for symbolic link, 's' for socket, 'p'
-   for fifo, '-' for any other file type */
-
-static char
-ftypelet (s)
-   struct stat *s;
-{
-  switch (s->st_mode & S_IFMT)
-    {
-    default:
-      return '-';
-    case S_IFDIR:
-      return 'd';
-#ifdef S_IFLNK
-    case S_IFLNK:
-      return 'l';
-#endif
-#ifdef S_IFCHR
-    case S_IFCHR:
-      return 'c';
-#endif
-#ifdef S_IFBLK
-    case S_IFBLK:
-      return 'b';
-#endif
-#ifdef S_IFMPC
-/* These do not seem to exist */
-    case S_IFMPC:
-    case S_IFMPB:
-      return 'm';
-#endif
-#ifdef S_IFSOCK
-    case S_IFSOCK:
-      return 's';
-#endif
-#ifdef S_IFIFO
-    case S_IFIFO:
-      return 'p';
-#endif
-#ifdef S_IFNWK /* hp-ux hack */
-    case S_IFNWK:
-      return 'n';
-#endif
-    }
-}
-\f
 /* rwx - look at read, write, and execute bits and set character
    flags accordingly. */
 
index 2d215792b42c048b24fe64c88b0310d811ff2672..19c26e9ec9312340a662b312b399d7a3a2b1a3e4 100644 (file)
@@ -30,7 +30,7 @@ Technology nor of any adaptation thereof in any advertising,
 promotional, or sales literature without prior written consent from
 MIT in each case. */
 
-/* $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/Attic/version.h,v 10.15 1987/12/16 19:39:33 cph Exp $
+/* $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/microcode/Attic/version.h,v 10.16 1987/12/18 00:02:45 cph Exp $
 
 This file contains version information for the microcode. */
 \f
@@ -46,7 +46,7 @@ This file contains version information for the microcode. */
 #define VERSION                10
 #endif
 #ifndef SUBVERSION
-#define SUBVERSION     15
+#define SUBVERSION     16
 #endif
 
 #ifndef UCODE_TABLES_FILENAME
index 3b2d07ea89d1ed44a1efc96938d5e8362e05b8ca..0d9996ab1e44e8eeccc087ef7cbfb48b5c05b920 100644 (file)
@@ -30,7 +30,7 @@ Technology nor of any adaptation thereof in any advertising,
 promotional, or sales literature without prior written consent from
 MIT in each case. */
 
-/* $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v8/src/microcode/version.h,v 10.15 1987/12/16 19:39:33 cph Exp $
+/* $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v8/src/microcode/version.h,v 10.16 1987/12/18 00:02:45 cph Exp $
 
 This file contains version information for the microcode. */
 \f
@@ -46,7 +46,7 @@ This file contains version information for the microcode. */
 #define VERSION                10
 #endif
 #ifndef SUBVERSION
-#define SUBVERSION     15
+#define SUBVERSION     16
 #endif
 
 #ifndef UCODE_TABLES_FILENAME