From owner-svn-src-all@FreeBSD.ORG Wed Oct 26 12:27:11 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 1233) id 676771065674; Wed, 26 Oct 2011 12:27:11 +0000 (UTC) Date: Wed, 26 Oct 2011 12:27:11 +0000 From: Alexander Best To: Ed Schouten Message-ID: <20111026122711.GA25999@freebsd.org> References: <201109290631.p8T6VgJ3008377@svn.freebsd.org> <20110929121457.GA53600@freebsd.org> <20111001130643.GC91943@hoeg.nl> <20111009011141.GA63608@freebsd.org> <20111009072008.GJ91943@hoeg.nl> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="pf9I7BMVVzbSWLtt" Content-Disposition: inline In-Reply-To: <20111009072008.GJ91943@hoeg.nl> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Edward Tomasz Napierala Subject: Re: svn commit: r225868 - head/bin/ps X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Oct 2011 12:27:11 -0000 --pf9I7BMVVzbSWLtt Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sun Oct 9 11, Ed Schouten wrote: > * Alexander Best , 20111009 03:11: > > is this what you had in mind? > > Yes, exactly. :-) here's an updated patch, which also includes a man page addition. please anybody feel free to commit. cheers. alex > > -- > Ed Schouten > WWW: http://80386.nl/ --pf9I7BMVVzbSWLtt Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="ps.diff" Index: bin/ps/ps.1 =================================================================== --- bin/ps/ps.1 (revision 226769) +++ bin/ps/ps.1 (working copy) @@ -29,7 +29,7 @@ .\" @(#)ps.1 8.3 (Berkeley) 4/18/94 .\" $FreeBSD$ .\" -.Dd October 1, 2011 +.Dd October 26, 2011 .Dt PS 1 .Os .Sh NAME @@ -437,6 +437,10 @@ .Ql - if the process can no longer reach that controlling terminal (i.e., it has been revoked). +A +.Ql - +without a preceding two letter abbreviation or pseudo-terminal device number +indicates a process which never had a controlling terminal. The full pathname of the controlling terminal is available via the .Cm tty keyword. Index: bin/ps/print.c =================================================================== --- bin/ps/print.c (revision 226769) +++ bin/ps/print.c (working copy) @@ -362,7 +362,7 @@ v = ve->var; dev = k->ki_p->ki_tdev; if (dev == NODEV) - str = strdup("??"); + str = strdup("-"); else asprintf(&str, "%#jx", (uintmax_t)dev); @@ -379,7 +379,7 @@ v = ve->var; dev = k->ki_p->ki_tdev; if (dev == NODEV || (ttname = devname(dev, S_IFCHR)) == NULL) - str = strdup("?? "); + str = strdup("- "); else { if (strncmp(ttname, "tty", 3) == 0 || strncmp(ttname, "cua", 3) == 0) @@ -403,7 +403,7 @@ v = ve->var; dev = k->ki_p->ki_tdev; if (dev == NODEV || (ttname = devname(dev, S_IFCHR)) == NULL) - ttname = "??"; + ttname = "-"; return (strdup(ttname)); } --pf9I7BMVVzbSWLtt--