Author: eadler
Date: Sat Mar  3 11:12:09 2018
New Revision: 330331
URL: https://svnweb.freebsd.org/changeset/base/330331

Log:
  MFC r325450:
  
  Fix cosmetic nit when printing out "override $mode" and "$owner/$group ..."
  
  The wrong index was being checked for == ' ' in the resulting stringified
  mode from strmode(3) -- it should have been the 11th value, not the 10th.
  
  PR:           76711

Modified:
  stable/11/bin/rm/rm.c
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/bin/rm/rm.c
==============================================================================
--- stable/11/bin/rm/rm.c       Sat Mar  3 11:11:07 2018        (r330330)
+++ stable/11/bin/rm/rm.c       Sat Mar  3 11:12:09 2018        (r330331)
@@ -515,7 +515,7 @@ check(const char *path, const char *name, struct stat 
                            "%s: -P was specified, but file is not writable",
                            path);
                (void)fprintf(stderr, "override %s%s%s/%s %s%sfor %s? ",
-                   modep + 1, modep[9] == ' ' ? "" : " ",
+                   modep + 1, modep[10] == ' ' ? "" : " ",
                    user_from_uid(sp->st_uid, 0),
                    group_from_gid(sp->st_gid, 0),
                    *flagsp ? flagsp : "", *flagsp ? " " : "",
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to