From: Theodore Ts'o Date: Wed, 7 Mar 2007 13:09:10 +0000 (-0500) Subject: Allow the debugfs lcd command to work w/o a filesystem being open X-Git-Tag: E2FSPROGS-1_40~116 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=57a1cbb643237b168bd4151aff3d3bad28bbc326;p=tools%2Fe2fsprogs.git Allow the debugfs lcd command to work w/o a filesystem being open Addresses LTC Bugzilla #27513 Signed-off-by: "Theodore Ts'o" --- diff --git a/debugfs/ChangeLog b/debugfs/ChangeLog index 4511cc9..aaed950 100644 --- a/debugfs/ChangeLog +++ b/debugfs/ChangeLog @@ -1,3 +1,9 @@ +2007-03-07 Theodore Tso + + * debugfs.c (do_lcd): Allow the lcd command when debugfs does not + currently have a filesystem open. + (Addresses LTC Bugzilla #27513) + 2007-01-28 Theodore Tso * unused.c: Fix bug so that the dump_unused command segfault if diff --git a/debugfs/debugfs.c b/debugfs/debugfs.c index cc99e81..3bddef9 100644 --- a/debugfs/debugfs.c +++ b/debugfs/debugfs.c @@ -181,9 +181,10 @@ print_usage: void do_lcd(int argc, char **argv) { - if (common_args_process(argc, argv, 2, 2, "lcd", - "", 0)) + if (argc != 2) { + com_err(argv[0], 0, "Usage: %s %s", argv[0], ""); return; + } if (chdir(argv[1]) == -1) { com_err(argv[0], errno,