statserial (1.1-22) direct (non packaging) changes

Summary

 Makefile     |    2 +-
 statserial.1 |    1 -
 statserial.c |    4 ++--
 3 files changed, 3 insertions(+), 4 deletions(-)

    
download this patch

Patch contents

--- statserial-1.1.orig/statserial.c
+++ statserial-1.1/statserial.c
@@ -42,7 +42,7 @@
 
 /* global variables */
 char device[255];                          /* name of device to open */
-const char *defaultDevice = "/dev/cua1";   /* default device if none specified on command line */
+const char *defaultDevice = "/dev/ttyS1";   /* default device if none specified on command line */
 int n_option = 0;                          /* set if -n option is used */
 int d_option = 0;                          /* set if -d option is used */
 int x_option = 0;                          /* set if -x option is used */
@@ -118,7 +118,7 @@
   parse_args(argc, argv);
 
   /* open port */
-  fd = open(device, O_RDONLY);
+  fd = open(device, O_RDONLY | O_NONBLOCK | O_NOCTTY);
   if (fd == -1) {
     char s[255];
     sprintf(s, "statserial: can't open device `%s'", device);
--- statserial-1.1.orig/Makefile
+++ statserial-1.1/Makefile
@@ -7,7 +7,7 @@
 
 # for production code
 CFLAGS	= -Wall -O3 -fomit-frame-pointer
-LDFLAGS = -s -N
+LDFLAGS = -s
 
 statserial:	statserial.o
 	$(LD) $(LDFLAGS) -o statserial statserial.o -lcurses
--- statserial-1.1.orig/statserial.1
+++ statserial-1.1/statserial.1
@@ -5,7 +5,6 @@
 .\" for conditions under which this file may be redistributed.
 .TH STATSERIAL 1 "17 December 1994" "Linux" "User Commands"
 .SH NAME
-
 statserial \- display serial port modem status lines
 
 .SH SYNOPSIS