diff options
author | Xin LI <delphij@FreeBSD.org> | 2016-12-26 17:34:27 +0000 |
---|---|---|
committer | Xin LI <delphij@FreeBSD.org> | 2016-12-26 17:34:27 +0000 |
commit | ed09c2c161ac033c7a916440269b0f6d38e792f2 (patch) | |
tree | 982d83de736e0bc374d3c70ef6aebf7164f4f249 /usr.sbin/pstat/pstat.c | |
parent | 62b0ff4e66c9c6f08d7f588efb1850377c0a2234 (diff) | |
download | src-ed09c2c161ac033c7a916440269b0f6d38e792f2.tar.gz src-ed09c2c161ac033c7a916440269b0f6d38e792f2.zip |
- 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.
MFC after: 2 weeks
Notes
Notes:
svn path=/head/; revision=310611
Diffstat (limited to 'usr.sbin/pstat/pstat.c')
-rw-r--r-- | usr.sbin/pstat/pstat.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/usr.sbin/pstat/pstat.c b/usr.sbin/pstat/pstat.c index 201784157329..b5ceb2e7c3d3 100644 --- a/usr.sbin/pstat/pstat.c +++ b/usr.sbin/pstat/pstat.c @@ -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"); |