From 8f45d909c1598adff96dc515b8efa1ab23e705ed Mon Sep 17 00:00:00 2001 From: antona Date: Fri, 3 Jun 2005 21:53:02 +0000 Subject: [PATCH] Only output message that volume is being set dirty if we are actually setting the dirty flag. Otherwise the message is pointless. --- ntfsprogs/mkntfs.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ntfsprogs/mkntfs.c b/ntfsprogs/mkntfs.c index daefcfac..077d0f45 100644 --- a/ntfsprogs/mkntfs.c +++ b/ntfsprogs/mkntfs.c @@ -3217,10 +3217,10 @@ static void create_file_volume(MFT_RECORD *m, MFT_REF root_ref, VOLUME_FLAGS fl) err = add_attr_vol_name(m, vol->vol_name, vol->vol_name ? strlen(vol->vol_name) : 0); if (!err) { - Qprintf("Setting the volume dirty so check disk runs on next " - "reboot into Windows.\n"); - err = add_attr_vol_info(m, fl, vol->major_ver, - vol->minor_ver); + if (fl & VOLUME_IS_DIRTY) + Qprintf("Setting the volume dirty so check disk runs " + "on next reboot into Windows.\n"); + err = add_attr_vol_info(m, fl, vol->major_ver, vol->minor_ver); } if (err < 0) err_exit("Couldn't create $Volume: %s\n", strerror(-err));