If the user specifies "e2fsck -j UUID=XXX", e2fsck should do blkid
interpretation, since e2fsck does it with the base file system name.
So from the sake of consistency and user convenience, we should do it
here too.
Addresses-Debian-Bug: #559315
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
goto sscanf_err;
break;
case 'j':
- ctx->journal_name = string_copy(ctx, optarg, 0);
+ ctx->journal_name = blkid_get_devname(ctx->blkid,
+ optarg, NULL);
+ if (!ctx->journal_name) {
+ com_err(ctx->program_name, 0,
+ _("Unable to resolve '%s'"),
+ optarg);
+ fatal_error(ctx, 0);
+ }
break;
case 'P':
res = sscanf(optarg, "%d", &ctx->process_inode_size);