Bug 277677 - /bin/rmdir should exit with status code 2 for invalid arguments
Summary: /bin/rmdir should exit with status code 2 for invalid arguments
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-13 22:41 UTC by Henrich Hartzer
Modified: 2024-06-08 04:53 UTC (History)
0 users

See Also:


Attachments
/bin/rmdir patch (984 bytes, patch)
2024-03-13 22:41 UTC, Henrich Hartzer
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Henrich Hartzer 2024-03-13 22:41:27 UTC
Created attachment 249139 [details]
/bin/rmdir patch

/bin/rmdir should exit with status 2 if invalid arguments are passed.
Comment 1 Henrich Hartzer 2024-04-10 21:49:57 UTC
Opened a pull request for this: https://github.com/freebsd/freebsd-src/pull/1161
Comment 2 commit-hook freebsd_committer freebsd_triage 2024-05-11 19:16:49 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/src/commit/?id=9bcc1b18c119148e4455e548c90b2bc9cef16d1b

commit 9bcc1b18c119148e4455e548c90b2bc9cef16d1b
Author:     Henrich Hartzer <henrichhartzer@tuta.io>
AuthorDate: 2024-05-10 17:53:49 +0000
Commit:     Warner Losh <imp@FreeBSD.org>
CommitDate: 2024-05-11 19:13:28 +0000

    /bin/rmdir: Exit with status 2 for invalid arguments

    PR: 277677

    Signed-off-by: Henrich Hartzer <henrichhartzer@tuta.io>
    Reviewed by: imp
    Pull Request: https://github.com/freebsd/freebsd-src/pull/1161

 bin/rmdir/rmdir.1             | 15 ++++++++-------
 bin/rmdir/rmdir.c             |  2 +-
 bin/rmdir/tests/rmdir_test.sh |  6 +++---
 3 files changed, 12 insertions(+), 11 deletions(-)