aboutsummaryrefslogtreecommitdiffstats
path: root/file_cmds/mtree/compare.c
diff options
context:
space:
mode:
authorCameron Katri <me@cameronkatri.com>2021-05-20 16:22:02 -0400
committerCameron Katri <me@cameronkatri.com>2021-05-20 16:22:02 -0400
commitf5569153b7df6d141164c27040ef0076732f2da7 (patch)
tree338e90c0f5de223bf790b85410838c0bc21cc61d /file_cmds/mtree/compare.c
parent591e92d95c376763dde539fadf0498bd1358073d (diff)
downloadapple_cmds-f5569153b7df6d141164c27040ef0076732f2da7.tar.gz
apple_cmds-f5569153b7df6d141164c27040ef0076732f2da7.tar.zst
apple_cmds-f5569153b7df6d141164c27040ef0076732f2da7.zip
file_cmds: 321.100.10.0.1
Diffstat (limited to 'file_cmds/mtree/compare.c')
-rw-r--r--file_cmds/mtree/compare.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/file_cmds/mtree/compare.c b/file_cmds/mtree/compare.c
index e585928..366f12f 100644
--- a/file_cmds/mtree/compare.c
+++ b/file_cmds/mtree/compare.c
@@ -534,11 +534,18 @@ typeerr: LABEL;
int supported;
struct timespec ptimespec = ptime(p->fts_accpath, &supported);
if (!supported) {
- LABEL;
- (void)printf("%stime added to parent folder expected %.24s.%09ld found that it is not supported\n",
- tab, ctime(&s->st_ptimespec.tv_sec), s->st_ptimespec.tv_nsec);
- tab = "\t";
- } else if (supported && ((s->st_ptimespec.tv_sec != ptimespec.tv_sec) ||
+ if (mflag) {
+ ptimespec.tv_sec = 0;
+ ptimespec.tv_nsec = 0;
+ supported = 1;
+ } else {
+ LABEL;
+ (void)printf("%stime added to parent folder expected %.24s.%09ld found that it is not supported\n",
+ tab, ctime(&s->st_ptimespec.tv_sec), s->st_ptimespec.tv_nsec);
+ tab = "\t";
+ }
+ }
+ if (supported && ((s->st_ptimespec.tv_sec != ptimespec.tv_sec) ||
(s->st_ptimespec.tv_nsec != ptimespec.tv_nsec))) {
if (!mflag) {
LABEL;