Hi,

I've been working on a line discipline for something else and I noticed
that the msts and endrun line disciplines are not displayed in pstat.
Here attached is a simple patch that fixes the issue.

This is also a practice run for me at submitting patches, so please let
me know if I'm doing things wrong.

Thanks,
Iain.
diff --git usr.sbin/pstat/pstat.8 usr.sbin/pstat/pstat.8
index d523b0014..d2631f834 100644
--- usr.sbin/pstat/pstat.8
+++ usr.sbin/pstat/pstat.8
@@ -212,11 +212,17 @@ TTYDISC (see
 .Xr termios 4 ) ,
 .Ql ppp
 for PPPDISC (see
-.Xr ppp 4 )
-and
+.Xr ppp 4 ) ,
 .Ql nmea
 for NMEADISC (see
-.Xr nmea 4 ) .
+.Xr nmea 4 ) ,
+.Ql msts
+for MSTSDISC (see
+.Xr msts 4 ) ,
+and
+.Ql endrun
+for ENDRUNDISC (see
+.Xr endrun 4 ) .
 .El
 .It Fl v
 Print the active vnodes.
diff --git usr.sbin/pstat/pstat.c usr.sbin/pstat/pstat.c
index 1684975c5..986dee90b 100644
--- usr.sbin/pstat/pstat.c
+++ usr.sbin/pstat/pstat.c
@@ -999,6 +999,12 @@ ttyprt(struct itty *tp)
 	case NMEADISC:
 		(void)printf("nmea\n");
 		break;
+	case MSTSDISC:
+		(void)printf("msts\n");
+		break;
+	case ENDRUNDISC:
+		(void)printf("endrun\n");
+		break;
 	default:
 		(void)printf("%d\n", tp->t_line);
 		break;

Reply via email to