From 4fcd676f6368a3955e0c831fc9f5de62d4e827e4 Mon Sep 17 00:00:00 2001 From: szaka Date: Sun, 12 Jun 2005 10:15:21 +0000 Subject: [PATCH] - More explanatory error message about failing to open a volume --- ntfsprogs/ntfsclone.c | 6 +++--- ntfsprogs/ntfsresize.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/ntfsprogs/ntfsclone.c b/ntfsprogs/ntfsclone.c index 5090fdc0..4cc57314 100644 --- a/ntfsprogs/ntfsclone.c +++ b/ntfsprogs/ntfsclone.c @@ -1094,10 +1094,10 @@ static void check_if_mounted(const char *device, unsigned long new_mntflag) if (mntflag & NTFS_MF_MOUNTED) { if (!(mntflag & NTFS_MF_READONLY)) - err_exit("Device %s is mounted read-write. " + err_exit("Device '%s' is mounted read-write. " "You must 'umount' it first.\n", device); if (!new_mntflag) - err_exit("Device %s is mounted. " + err_exit("Device '%s' is mounted. " "You must 'umount' it first.\n", device); } } @@ -1115,7 +1115,7 @@ static void mount_volume(unsigned long new_mntflag) int err = errno; - perr_printf("ntfs_mount failed"); + perr_printf("Opening '%s' as NTFS failed", opt.volume); if (err == EINVAL) { Printf("Apparently device '%s' doesn't have a " "valid NTFS. Maybe you selected\nthe whole " diff --git a/ntfsprogs/ntfsresize.c b/ntfsprogs/ntfsresize.c index cccf34b1..aa4ef0ca 100644 --- a/ntfsprogs/ntfsresize.c +++ b/ntfsprogs/ntfsresize.c @@ -2057,10 +2057,10 @@ static ntfs_volume *mount_volume(void) } if (mntflag & NTFS_MF_MOUNTED) { if (!(mntflag & NTFS_MF_READONLY)) - err_exit("Device %s is mounted read-write. " + err_exit("Device '%s' is mounted read-write. " "You must 'umount' it first.\n", opt.volume); if (!opt.ro_flag) - err_exit("Device %s is mounted. " + err_exit("Device '%s' is mounted. " "You must 'umount' it first.\n", opt.volume); } @@ -2068,7 +2068,7 @@ static ntfs_volume *mount_volume(void) int err = errno; - perr_printf("ntfs_mount failed"); + perr_printf("Opening '%s' as NTFS failed", opt.volume); if (err == EINVAL) printf(invalid_ntfs_msg, opt.volume); else if (err == EIO)