svn commit: r255616 - stable/9/usr.sbin/mtree
Xin LI
delphij at FreeBSD.org
Mon Sep 16 16:43:58 UTC 2013
Author: delphij
Date: Mon Sep 16 16:43:57 2013
New Revision: 255616
URL: http://svnweb.freebsd.org/changeset/base/255616
Log:
MFC r255483:
Do not emit size for non-regular files. There is nothing that
mtree(1) can do in this situation and would cause confusion.
Modified:
stable/9/usr.sbin/mtree/create.c
Directory Properties:
stable/9/usr.sbin/mtree/ (props changed)
Modified: stable/9/usr.sbin/mtree/create.c
==============================================================================
--- stable/9/usr.sbin/mtree/create.c Mon Sep 16 15:10:11 2013 (r255615)
+++ stable/9/usr.sbin/mtree/create.c Mon Sep 16 16:43:57 2013 (r255616)
@@ -208,7 +208,7 @@ statf(int indent, FTSENT *p)
output(indent, &offset, "mode=%#o", p->fts_statp->st_mode & MBITS);
if (keys & F_NLINK && p->fts_statp->st_nlink != 1)
output(indent, &offset, "nlink=%u", p->fts_statp->st_nlink);
- if (keys & F_SIZE)
+ if (keys & F_SIZE && S_ISREG(p->fts_statp->st_mode))
output(indent, &offset, "size=%jd",
(intmax_t)p->fts_statp->st_size);
if (keys & F_TIME)
More information about the svn-src-stable-9
mailing list