svn commit: r244996 - head/usr.sbin/newsyslog

Mark Johnston markj at FreeBSD.org
Thu Jan 3 16:12:49 UTC 2013


Author: markj
Date: Thu Jan  3 16:12:48 2013
New Revision: 244996
URL: http://svnweb.freebsd.org/changeset/base/244996

Log:
  Have -n imply -r, since dry-run mode obviously doesn't require root
  privileges.
  
  Approved by:	rstone (co-mentor)
  MFC after:	1 week

Modified:
  head/usr.sbin/newsyslog/newsyslog.8
  head/usr.sbin/newsyslog/newsyslog.c

Modified: head/usr.sbin/newsyslog/newsyslog.8
==============================================================================
--- head/usr.sbin/newsyslog/newsyslog.8	Thu Jan  3 16:11:24 2013	(r244995)
+++ head/usr.sbin/newsyslog/newsyslog.8	Thu Jan  3 16:12:48 2013	(r244996)
@@ -125,7 +125,9 @@ reasons for either trimming that log or 
 Cause
 .Nm
 not to trim the logs, but to print out what it would do if this option
-were not specified.
+were not specified. This option implies the
+.Fl r
+option.
 .It Fl r
 Remove the restriction that
 .Nm

Modified: head/usr.sbin/newsyslog/newsyslog.c
==============================================================================
--- head/usr.sbin/newsyslog/newsyslog.c	Thu Jan  3 16:11:24 2013	(r244995)
+++ head/usr.sbin/newsyslog/newsyslog.c	Thu Jan  3 16:12:48 2013	(r244996)
@@ -644,7 +644,7 @@ parse_args(int argc, char **argv)
 			break;
 		case 'n':
 			noaction++;
-			break;
+			/* FALLTHROUGH */
 		case 'r':
 			needroot = 0;
 			break;


More information about the svn-src-all mailing list