Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 9 Jan 2017 05:58:48 +0000 (UTC)
From:      Xin LI <delphij@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r311753 - stable/10/usr.sbin/pstat
Message-ID:  <201701090558.v095wmEg004329@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: delphij
Date: Mon Jan  9 05:58:48 2017
New Revision: 311753
URL: https://svnweb.freebsd.org/changeset/base/311753

Log:
  MFC r310611:
  
   - pstat(8) does not accept any arguments other than getopt() args,
     so don't bother to adjust argc/argv after getopt() loop.
   - Make a string pointer constant.

Modified:
  stable/10/usr.sbin/pstat/pstat.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/usr.sbin/pstat/pstat.c
==============================================================================
--- stable/10/usr.sbin/pstat/pstat.c	Mon Jan  9 05:57:31 2017	(r311752)
+++ stable/10/usr.sbin/pstat/pstat.c	Mon Jan  9 05:58:48 2017	(r311753)
@@ -174,8 +174,6 @@ main(int argc, char *argv[])
 		default:
 			usage();
 		}
-	argc -= optind;
-	argv += optind;
 
 	/*
 	 * Initialize symbol names list.
@@ -339,7 +337,7 @@ static void
 ttyprt(struct xtty *xt)
 {
 	int i, j;
-	char *name;
+	const char *name;
 
 	if (xt->xt_size != sizeof *xt)
 		errx(1, "struct xtty size mismatch");



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201701090558.v095wmEg004329>