Skip to content

cksum: show error if a directory is specified #5805

@cakebaker

Description

@cakebaker

GNU cksum shows an error and returns an exit code of 1 if a directory is specified:

$ cksum dir file
cksum: dir: Is a directory
4294967295 0 file
$ echo $?
1

uutils cksum, on the other hand, doesn't show an error and returns an exit code of 0:

$ cargo run cksum dir file
4294967295 0 dir
4294967295 0 file
$ echo $?
0

The same applies to -a/--algorithm with all algorithms.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions