ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/rt/suncom.c
(Generate patch)

Comparing ray/src/rt/suncom.c (file contents):
Revision 1.1 by greg, Thu Feb 2 10:41:44 1989 UTC vs.
Revision 1.3 by greg, Thu Feb 22 12:39:26 1990 UTC

# Line 11 | Line 11 | static char SCCSid[] = "$SunId$ LBL";
11   */
12  
13   #include  <stdio.h>
14 #include  <signal.h>
14   #include  <sys/ioctl.h>
15  
16   #define INITSTR         ""              /* TTY initialization string */
# Line 23 | Line 22 | main(argc, argv)               /* called with pid to signal and pip
22   int     argc;
23   char    *argv[];
24   {
26        int  sigpid;
25          int  outfd;
26  
27 <        if (argc != 3)
27 >        if (argc != 2)
28                  exit(1);
29 <        sigpid = atoi(argv[1]);
32 <        outfd = atoi(argv[2]);
29 >        outfd = atoi(argv[1]);
30  
31          fputs(INITSTR, stdout);
32          fflush(stdout);
# Line 47 | Line 44 | char   *argv[];
44          ioctl(0, TIOCSETP, &ttymode);
45                                                  /* read lines from input */
46          for ( ; ; ) {
47 <                ungetc(getc(stdin), stdin);     /* notify sigpid */
48 <                kill(sigpid, SIGIO);
47 >                ungetc(getc(stdin), stdin);     /* notify caller */
48 >                putc(' ', stdout);
49 >                fflush(stdout);
50                  sendline();
51          }
52   }
# Line 75 | Line 73 | sendline()                             /* read a line in raw mode */
73   {
74          char  buf[256];
75  
76 <        editline(buf, getch, sends, ttymode.sg_erase, ttymode.sg_kill);
76 >        editline(buf, getch, sends);
77          putc('\0', stdout);
78          sends(buf);
79   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines